72分求调
查看原帖
72分求调
1820099
Lee0723楼主2025/8/5 16:29
#include <stdio.h>
int main()
{
    int s,v,t1,sumt,h,min;
    double t;
    int hp,minp;
    scanf("%d %d",&s,&v);
    t=(s*1.0)/v;
    t1=s/v;
    if(t1<t){
        t=t1+1;
    }
    sumt=t+10;
    h=sumt/60;
    min=sumt%60;
    minp=60-min;
    hp=8-1-h;
    if(hp<0){
        hp=24+hp;
    }
    if(hp>=0&&hp<=9){
        printf("0%d:%d",hp,minp);
    }
    else{
        printf("%d:%d",hp,minp);
    }
    return 0;
}

2025/8/5 16:29
加载中...