package chap1; public class Main { public static void main(String[] args) { int a = 10, b = 5, c; c = a; a = b; b = c; System.out.println("a=" + a + " b=" + b); int d = 345; int ge = d % 10; int shi = d % 100 / 10; int bai = d / 100; System.out.println("各位数之和=" + (ge + shi + bai)); float f = 50f; System.out.println("50华氏度的摄氏度为:" + (f - 32) * 5 / 9); char g = 'A'; System.out.println("转换为小写字母为:" + (char)(g + 32)); } }
第一次上机练习
猜你喜欢
转载自www.cnblogs.com/110ctc/p/12522915.html
今日推荐
周排行