- Joined
- May 12, 2010
- Messages
- 1
- Reaction score
- 0
I'm a college student and have an assignment where I have to create String and Float arrays for provided test date.
I believe I understand that I have to declare it in my declarations:
String TransTypeArray[]; //The TransType Array
String TransDateArray[]; //The Transaction Date Array
float TransAmtArray[]; //The Transaction Amount Array
float RunBalArray[]; //The Running Balance Array
Then I created it in my main:
TransTypeArray = new String[8];
TransDateArray = new String[7];
TransAmtArray = new float[7];
RunBalArray = new float[7];
What I'm not clear on is how to initilize it.
I'm assuming what happens is when I enter in the data as an input it stores it?
I don't get how to make that happen here:
System.out.print("Input TransType: ");
TransType = stdin.readLine();
Am I reading the assignment wrong???
The transType, transDate and transAmt arrays should be initialized within the Java source code to store the Project #5 Test Data. The currBal array values should be assigned as those values are calculated during the execution of the program.
I believe I understand that I have to declare it in my declarations:
String TransTypeArray[]; //The TransType Array
String TransDateArray[]; //The Transaction Date Array
float TransAmtArray[]; //The Transaction Amount Array
float RunBalArray[]; //The Running Balance Array
Then I created it in my main:
TransTypeArray = new String[8];
TransDateArray = new String[7];
TransAmtArray = new float[7];
RunBalArray = new float[7];
What I'm not clear on is how to initilize it.
I'm assuming what happens is when I enter in the data as an input it stores it?
I don't get how to make that happen here:
System.out.print("Input TransType: ");
TransType = stdin.readLine();
Am I reading the assignment wrong???
The transType, transDate and transAmt arrays should be initialized within the Java source code to store the Project #5 Test Data. The currBal array values should be assigned as those values are calculated during the execution of the program.