OK, here's a reply to my own post. But it should reveal why I don't think it's a problem with data types. This will trim out some of the debugging code, but what you'll see it that only an occasional assignment is not made:
@row is assigned 31 Medium Orange carb 14 2 0.2 @athlete[$i,$j] is assigned the value @athlete[$i,$j] is assigned the value Medium Orange @athlete[$i,$j] is assigned the value carb @athlete[$i,$j] is assigned the value 14 @athlete[$i,$j] is assigned the value 2 @athlete[$i,$j] is assigned the value 0.2 @row is assigned 42 1/2 c. (cooked) past carb 19.5 3.2 0.4 @athlete[$i,$j] is assigned the value 42 42 @athlete[$i,$j] is assigned the value @athlete[$i,$j] is assigned the value carb @athlete[$i,$j] is assigned the value 19.5 @athlete[$i,$j] is assigned the value 3.2 @athlete[$i,$j] is assigned the value 0.4 @row is assigned 26 1/2 c. canned peache carb 14 1 0 @athlete[$i,$j] is assigned the value 26 0.4 @athlete[$i,$j] is assigned the value 1/2 c. canned peache 1/2 c. cann +ed peache @athlete[$i,$j] is assigned the value @athlete[$i,$j] is assigned the value 14 @athlete[$i,$j] is assigned the value 1 @athlete[$i,$j] is assigned the value 0 @row is assigned 6 White Bread III carb 24.5 4.1 2.3 @athlete[$i,$j] is assigned the value 6 @athlete[$i,$j] is assigned the value White Bread III 0 @athlete[$i,$j] is assigned the value carb carb @athlete[$i,$j] is assigned the value @athlete[$i,$j] is assigned the value 4.1 @athlete[$i,$j] is assigned the value 2.3 @row is assigned 20 Marias Spanish Rice carb 42.4 4.3 5 @athlete[$i,$j] is assigned the value 20 @athlete[$i,$j] is assigned the value Marias Spanish Rice @athlete[$i,$j] is assigned the value carb 2.3 @athlete[$i,$j] is assigned the value 42.4 42.4 @athlete[$i,$j] is assigned the value @athlete[$i,$j] is assigned the value 5
See what I mean? It just seems to almost be caching or writing out of order. I'm sure it's my mistake, but I sure don't know why it's doing this. These are the results from my original code base.

In reply to Re: Where is my foreach data going to? by brotherdaniel
in thread Where is my foreach data going to? by brotherdaniel

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.