2 条题解

  • 0
    @ 2026-5-17 14:33:37
    #include<bits/stdc++.h>
    using namespace std;
    int main(){
    	int a,b;scanf("%d%d",&a,&b);
    	if(a>0)puts("Positive");
    	else if(b<0){
    		if(b-a+1&1)puts("Negative");
    		else puts("Positive");
    	}
    	else puts("Zero");
    	return 0;
    }
    • 0
      @ 2026-1-21 13:12:49

      水题解!!!

      #include<bits/stdc++.h>
      using namespace std;
      int main()
      {
      	int a,b;scanf("%d%d",&a,&b);
      	if(a>0)puts("Positive");
      	else if(b<0)
      	{
      		if(b-a+1&1)puts("Negative");
      		else puts("Positive");
      	}
      	else puts("Zero");
      	return 0;
      }
      
      • 1

      信息

      ID
      8368
      时间
      2000ms
      内存
      256MiB
      难度
      3
      标签
      递交数
      57
      已通过
      29
      上传者