Hi,I was trying to print numbers from an array(as stated in the comment) but the result always turns out different. Can anyone please review the attached picture and correct me? Thanks in advance.
Hi,I was trying to print numbers from an array(as stated in the comment) but the result always turns out different. Can anyone please review the attached picture and correct me? Thanks in advance.
Look at your print statement and think about what it is printing.
Ask yourself, what the heck is num?
You aren't even using your array.
The num variable is being used in an uninitialized state.
Your loop merely prints 300 copies of the same number
There's nothing in there to decide if a number is less than 300 or not.
Back to the ole drawing board, methinks....
Got it guys..thanks!