题解 | #简单运算#

简单运算

http://www.nowcoder.com/practice/6817945637dd4a31811d38313653e967

import java.util.Scanner;

public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int a = scanner.nextInt(); int b = scanner.nextInt(); scanner.close(); int shu1=a+b; int shu5=a*b; int shu2,shu3,shu4; if(a>b){ shu2=a-b; shu3=a/b; shu4=a%b; } else{ shu2=b-a; shu3=b/a; shu4=b%a; } System.out.print(shu1+" "+shu2+" "+shu5+" "+shu3+" "+shu4); //write your code here......

}

}

全部评论

相关推荐

06-23 11:28
门头沟学院 Java
牛客91966197...:也有可能是点拒绝的时候自动弹的话术
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务