题目来源:牛客网 编程初学者入门训练 BC30 KiKi和酸奶
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); int h = sc.nextInt(); int k = sc.nextInt(); int res = 0; if(k % h != 0) { res = n - k/h - 1; } else { res = n - k/h; } System.out.println(res); } }
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)