31 条题解

  • -1
    @ 2024-4-6 12:36:57

    #include #include #include #include #include #include const int N = 1e5 + 10; const int INF = 0x3f3f3f3f; using namespace std; int n; int main(){ cin>>n; if(n>0) { cout<<"positive"; return 0; } n==0?cout<<"zero":cout<<"negative"; return 0; }

    • -1
      @ 2024-4-5 21:30:23

      #include <bits/stdc++.h> using namespace std; int main(){ int n; cin >> n; if (n == 0){ cout << "zero"; }else if (n < 0){ cout << "negative"; }else{ cout << "positive"; } return 0; }

      • -1
        @ 2024-3-24 14:00:36

        #include <stdio.h> #include #include <math.h> using namespace std; int main() { int a; cin>>a; if(a>0) { cout<<"positive"; }

        else if(a<0)
        {
        	cout<<"negative";			    
        }
        
        else if(a==0)
        {
        	cout<<"zero";						
        }
        
        return 0;
        

        }

        • -1
          @ 2023-4-10 17:04:59
          #include <bits/stdc++.h>
          using namespace std;
          int main(){
              int n;
              cin >> n;
              if (n == 0){
                  cout << "zero";
              }else if (n < 0){
                  cout << "negative";
              }else{
                  cout << "positive";
          	}
              return 0;
          }
          
          • -1
            @ 2023-4-4 20:56:09

            #include<bits/stdc++.h> using namespace std; int main() { int n; cin>>n; if(n>0) cout<<"positive"; if(n==0) cout<<"zero"; if(n<0) cout<<"negative"; return 0; }

            • -1
              @ 2023-1-2 15:17:58
              #include<iostream>
              using namespace std;
              int main(){
                  int n;
                  cin >> n;
                  if (n == 0){
              		cout<<"zero";
              	}else{
                  	if (n < 0){
                  	cout<<"negative";
              		}else{
                  	cout<<"positive";
                  	}
              	}
              }
              
              • -1
                @ 2022-12-4 15:55:06
                #include <bits/stdc++.h>
                
                using namespace std;
                
                int main()
                {
                    int n;
                
                    cin >> n;
                
                    if (n == 0)
                    {
                        cout << "zero";
                    }
                    else if (n < 0)
                    {
                        cout << "negative";
                    }
                    else if (n > 0)
                    {
                        cout << "positive";
                    }
                
                    return 0;
                }
                
                • -1
                  @ 2022-9-3 14:45:55
                  #include <bits/stdc++.h>
                  
                  using namespace std;
                  
                  int main()
                  {
                      int n;
                  
                      cin >> n;
                  
                      if (n == 0)
                      {
                          cout << "zero";
                      }
                      else if (n < 0)
                      {
                          cout << "negative";
                      }
                      else if (n > 0)
                      {
                          cout << "positive";
                      }
                  
                      return 0;
                  }
                  
                  • -2
                    @ 2024-4-12 20:06:59

                    #include #include <stdio.h> #include #include <math.h> using namespace std; int main() { int N; cin>>N; if(N>0) { cout<<"positive"; } if(N==0){ cout<<"zero"; } if(N<0){ cout<<"negative"; } return 0; }

                    • -2
                      @ 2022-1-2 15:54:56
                      #include <stdio.h>
                      #include <iostream>
                      #include <math.h>
                      #include <iomanip>
                      using namespace std;
                      int main()
                      {
                      	int N;
                      	cin >>N;
                      	if(N<0)
                      	{
                      		cout<<"negative";
                      	}
                      	else if(N==0)
                      	{
                      		cout<<"zero";
                      	}
                      	else
                      	{
                      		cout<<"positive";
                      	}
                      }
                      
                      • -3
                        @ 2022-1-2 15:49:55
                        #include <stdio.h>
                        #include <iostream>
                        #include <math.h>
                        #include <iomanip>
                        using namespace std;
                        int main()
                        {
                        	int N;
                        	cin >>N;
                        	if(N<0)
                        	{
                        		cout<<"negative";
                        	}
                        	else if(N==0)
                        	{
                        		cout<<"zero";
                        	}
                        	else
                        	{
                        		cout<<"positive";
                        	}
                        }
                        

                        信息

                        ID
                        868
                        时间
                        1000ms
                        内存
                        128MiB
                        难度
                        4
                        标签
                        递交数
                        953
                        已通过
                        454
                        上传者