Hint: for loops can go from 0 to n with a positive increment or from n to 0 with a negative increment. You just need to adjust the parameters(e.g. starting point) to handle your list.
Regards,...
Type: Posts; User: jim829
Hint: for loops can go from 0 to n with a positive increment or from n to 0 with a negative increment. You just need to adjust the parameters(e.g. starting point) to handle your list.
Regards,...
You need to rethink your strategy. You shouldn't be putting the display loop inside the input loop.
To recap, here is what I think you should be doing.
1. Enter the numbers via the scanner and...
You don't need to use 'line'. Just use 'i'. And start it at 0 since arrays are zero based. So it would be NUM[i] =helnet;
Regards,
Jim