Ideas:
Enter a Fahrenheit to Celsius in accordance with the conversion formula to
Code:
public class Demo1 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
System.out.println("请华氏温度:");
int huashi = sc.nextInt();
float c= (float)(huashi-32)*5/9;
System.out.println(""+c);
}
}
operation result: