Append data from user input into array
I need a little help with this assignment. I'm trying to figure out what the code is for appending a user input into arrays. There are 3 arrays (String, double, and int), and each of them has a size of 100. I'm using a switch statement; when a user keys 1 and hits enter, it will prompt the user for the string value (for the string array), the double value (for the double array) and then the int value (for the int array). I keep overwriting the first element of each array (obviously). The question is, how do I append it to the next available empty slot in the array? Btw this is all done in a console, so no GUI.
Re: Append data from user input into array
Welcome to the forums.
Please show us the code you have written so far..
Don't forget to add the [highlight=Java] code [/highlight] tags.