7 solutions

  • 1
    @ 2023-9-10 16:02:59
    #include <set>
    #include <ios>
    #include <list>
    #include <cmath>
    #include <ctime>
    #include <queue>
    #include <deque>
    #include <stack>
    #include <vector>
    #include <bitset>
    #include <cctype>
    #include <cerrno>
    #include <cwchar>
    #include <cstdio>
    #include <fenv.h>
    #include <iosfwd>
    #include <string>
    #include <limits>
    #include <math.h>
    #include <cstdlib>
    #include <iomanip>
    #include <clocale>
    #include <complex>
    #include <cstring>
    #include <cstring>
    #include <cwctype>
    #include <istream>
    #include <ostream>
    #include <sstream>
    #include <fstream>
    #include <utility>
    #include <stdio.h>
    #include <iostream>
    #include <stdint.h>
    #include <string.h>
    #include <tgmath.h>
    #include <complex.h>
    #include <algorithm>
    #include <exception>
    #include <stdbool.h>
    #include <stdexcept>
    #include <streambuf>
    #include <functional>
    #include <inttypes.h>
    #include <bits/stdc++.h>
    using namespace std;
    int main(){
    	string n;
    	cin>>n;
    	if(n[0] == '-') cout<<n;
    	else cout<<"-"<<n;
    	return 0;
    	
    }
    
    
    • 0
      @ 2024-4-3 19:42:48
      #include<iostream>
      using namespace std;
      int main(){
      	string s;
      	cin>>s;
      	if(s[0]!='-')
      		s="-"+s;
      	cout<<s;
      }
      
      • 0
        @ 2023-11-24 21:26:31
        #include<iostream>
        using namespace std;
        int main(){
        	string a;
        	cin>>a;
        	if(a[0]=='-')cout<<a;
        	else cout<<"-"<<a;
        }
        
        • 0
          @ 2023-10-30 16:45:45
          #include <iostream>
          #include <cstdio>
          #include <iomanip>
          #include <cmath>
          using namespace std;
          int we[100000000];
          int main(){
          	string s;
          	cin >> s;
          
          	cout << "-";
          	cout << s;
          	return 0;
          }
          
          • 0
            @ 2023-9-16 16:47:44
            #include<bits/stdc++.h>
            using namespace std;
            int main(){
                char a[100];
                cout<<"-";
                while(cin>>a) cout<<a;
                return 0;
            }
            
            • 0
              @ 2023-9-16 14:42:51

              #include<bits/stdc++.h> using namespace std; int main(){ char a[100]; cout<<"-"; while(cin>>a) cout<<a; return 0; }

              • 0
                @ 2023-9-16 14:42:37

                #include<bits/stdc++.h> using namespace std; int main(){ char a[100]; cout<<"-"; while(cin>>a) cout<<a; return 0; }

                • 1

                Information

                ID
                492
                Time
                1000ms
                Memory
                256MiB
                Difficulty
                8
                Tags
                # Submissions
                390
                Accepted
                59
                Uploaded By