Run ID:137188

提交时间:2025-11-16 15:28:11

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int p,e,i,d,s; cin>>p>>e>>i>>d; for(int k=p+23;p<=21252;k+=23){ for(int j=e+23;j<=21252;j+=28){ for(int x=i+23;x<=21252;x+=33){ if(k==j && j==x){ cout<<"the next triple peak occurs in "<<k-d<<" days."; return 0; } } } } return 0; }