I am a very beginner in programming and in the process of creating a huge program and am stuck for the part of the program. Here is the method where I am stuck,
public static void convert ()
{
Scanner input = new Scanner (System.in);
System.out.println(" Please enter a Celsius Temprature value ");
double celsius= input.nextDouble();
double fahrenheit = (9.0/5)* celsius + 32;
System.out.println( celsius + " C " + fahrenheit + " F " );
}
What needs to be done here is, one array that will store the input (celsius value here) and the other one that will store the conversion (fahrenheit value here). I have already used a loop that will allow user input and thus calculation as many as times needed, but if someone can help with the arrays part of this, it will be really appreciated.
In addition, any decent simple to follow tutorial for Java will be great as well.
Thanks very much in advance.

New Topic/Question
Reply




MultiQuote







|