PAT团队程序设计天梯赛-习题集L1-004 计算摄氏温度

题目链接

示例代码

import java.util.Scanner;
public class L1_004 {
	
	public static void main(String[] args) {
		int f = 0;
		Scanner sc = new Scanner(System.in);
		String input = sc.nextLine();
		sc.close();
		f = Integer.parseInt(input);
		System.out.println("Celsius = " + 5*(f-32)/9);
	}
}

猜你喜欢

转载自blog.csdn.net/qq_38234015/article/details/80209691
今日推荐