我第一题怎么读取数据都不对不知道为什么,本地测试就是通过的。 Scanner sc = new Scanner(System.in); int high = 0,inSpeed = 0,outSpeed = 0,breakPoint = 0,time = 0; while(sc.hasNextInt()){ high = sc.nextInt(); inSpeed = sc.nextInt(); outSpeed = sc.nextInt(); breakPoint = sc.nextInt(); time = sc.nextInt(); aboutWater(high,inSpeed,outSpeed,breakPoint,time); }
点赞 5

相关推荐

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