I'm relatively new to java, and after much searching, I just can't pair up any solutions of related issues to mine. I'm trying to implement a very simple method to write to/ read from an array, and it's not being recognized by the compiler. "Keyboard" is a "variable not recognized" either. Here's a declaration of the array, with the method a bit further down that works on it... (first time long time btw :) Many thanks in advance...
private static void loadMakeModelYear()
import java.util.Scanner;
String [][] makeModelYear = {{"Make", "Model", "Year"},{"Blank", "Blank", "Blank"}};
private static void loadMakeModelYear()
{
for (int i = 0; i < 3; i++)
{
System.out.println("Please enter a " + makeModelYear[i][0]);
makeModelYear [i][1] = keyboard.nextLine();
}
}
keyboardvariable declared anywhere?