2 条题解

  • 0
    @ 2026-5-30 10:01:05
    #include<bits/stdc++.h>
    using namespace std;
    int s[10];
    void end(){puts("No");exit(0);}
    int main()
    {
    	s[0]=0;
    	for(int i=1;i<=8;i++)
    	{
    		scanf("%d",&s[i]);
    		if(s[i]<s[i-1])end();
    		if(s[i]<100||s[i]>675)end();
    		if(s[i]%25!=0)end();
    	}
    	puts("Yes");return 0;
    }
    
    • 0
      @ 2026-5-17 14:36:16
      #include<bits/stdc++.h>
      using namespace std;
      int main(){
      	int a[9], x = 0;
      	a[0] = -2e9;
      	for(int i = 1; i <= 8; i++){
      		cin >> a[i];
      		if(a[i] < a[i-1]){
      			cout << "No";
      			return 0;
      		}
      	}
      	for(int i = 1; i <= 8; i++){
      		if(a[i] <= 675 && a[i] >= 100){
      			if(a[i] % 25 == 0){
      				x++;
      			}
      		}
      	}
      	if(x == 8) cout << "Yes";
      	else cout << "No";
      	return 0;
      }
      • 1

      信息

      ID
      9104
      时间
      2000ms
      内存
      1024MiB
      难度
      6
      标签
      递交数
      31
      已通过
      11
      上传者