求助佬们,第二点为何为re?
查看原帖
求助佬们,第二点为何为re?
1047750
Dream_liu楼主2023/8/5 23:27
#include<iostream>
using namespace std;
int main()
{
   int m,t,s;
   cin >> m >> t >> s;
   int ans = m - (s / t);
   if(t != 0)
   {  
       if(s % t == 0)
        {
          cout << max(ans,0) << endl;
        }
       else
        {
          cout << max(ans - 1,0) << endl;
        }
   }
   else 
   {  
      cout << 0 << endl;
   }
   system("pause");
   return 0;
}
2023/8/5 23:27
加载中...