PT Java Unique System 4th Quarter Antonio
PT Java Unique System 4th Quarter Antonio
2 in 1 Temperature Calculator
System.out.println("\n");
}
System.out.println("Converting: " + celsius + "°C");
System.out.println("1 : " + total);
System.out.println("2 : " + total2);
System.out.println("3 : " + total3);
System.out.println("4 : " + total4);
System.out.println("5 : " + total5);
System.out.println("Result: " + String.format("%.1f",result) + "°F");
System.out.println("\n");
System.out.println("Calculating...");
System.out.println("°F to °C");
f9 = fahrenheit - 32;
for(double f = 5; f == 5; f++){
f1 = f2 + f;
f3 = f9 * f1;
}
for(double f11 = 1; f11 <= 7; f11++){
f10 = f10 + f11;
}
for(double f8 = 1; f8 <= 8; f8++){
f4 = f4 + f8;
f6 = f4 - f10 + 0.5;
f7 = f3 / f6;
}
System.out.println("Converting: " + fahrenheit + "°F");
System.out.println("1 : " + f9);
System.out.println("2 : " + f3);
System.out.println("3 : " + f6);
System.out.println("Result: " + String.format("%.1f",f7) + "°C");
}
System.out.println("Converting: " + fahrenheit + "°F");
System.out.println("1 : " + f9);
System.out.println("2 : " + f3);
System.out.println("3 : " + f6);
System.out.println("Result: " + String.format("%.1f",f7) + "°C");
System.out.println("\n");
System.out.println("Calculating...");
System.out.println("°C to °F");
}
System.out.println("Converting: " + celsius + "°C");
System.out.println("1 : " + total);
System.out.println("2 : " + total2);
System.out.println("3 : " + total3);
System.out.println("4 : " + total4);
System.out.println("5 : " + total5);
System.out.println("Result: " + String.format("%.1f",result) + "°F");
}else{
System.out.println("Invalid (please enter a number)");
}
}
}