java第一个和第五个WA卡住了,不知道哪里有问题
查看原帖
java第一个和第五个WA卡住了,不知道哪里有问题
687714
LoveYing楼主2022/3/3 22:05
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        Scanner cin = new Scanner(System.in);
        int m = cin.nextInt();
        int t = cin.nextInt();
        int s = cin.nextInt();
        int n = 0;
        if(t == 0){
            System.out.println(n);
        }
        else {
            if (s % t == 0) {
                n = m - s / t;
            } else {
                n = m - s / t - 1;
            }
            System.out.println(n);
        }
    }

}
2022/3/3 22:05
加载中...