Submission #855677


Source Code Expand

Copy
#include<iostream>
#include<
 using namespace std;

int main(){
string s;
cin>>s;
int char[26]={0};
for(int i=0;s[i]!='/0';i++){
if(char[s[i]-97]==0)
char[s[i]-97]=1;
else char[s[i]-97]=0;
}

for(int i=0;i<n;i++){
if (char[i]='1'){cout<<"No";return 0;}
}
cout<<"Yes";
}

Submission Info

Submission Time
Task B - 美しい文字列 / Beautiful Strings
User Deragonite
Language C++14 (GCC 5.4.1)
Score 0
Code Size 287 Byte
Status

Compile Error

./Main.cpp:2:10: error: missing terminating > character
 #include<
          ^
./Main.cpp:2:9: error: empty filename in #include
 #include<
         ^
./Main.cpp:9:19: warning: multi-character character constant [-Wmultichar]
 for(int i=0;s[i]!='/0';i++){
                   ^
./Main.cpp: In function ‘int main()’:
./Main.cpp:8:9: error: expected unqualified-id before ‘[’ token
 int char[26]={0};
         ^
./Main.cpp:10:4: error: expected primary-expression before ‘char’
 if(char[s[i]-97]==0)
    ^
./Main.cpp:10:4: error: expected ‘)’ before ‘char’
./Main.cpp:11:5: error: expected unqualified-id before ‘[’ token
 char[s[i]-97]=1;
     ^
./Main.cpp:12:10: error: expected unqualified-id before ‘[’ token
 else char[s[i]-97]=0;
          ^
./Main.cpp:15:15: error: ‘n’ was not declared in this scope
 for(int i=0;i<n;i++){
               ^
./Main.cpp:16:5: error: expected primary-expression before ‘char’
 if (char[i]='1'){cout<<"No";return 0;}
     ^
./Main.cpp:16:5: error: expected ‘)’ before ‘char’