/*
#include<string.h>
#include<stdio.h>
int main()
{
char str[10000]={};
int i, j, n;
scanf("%d",&n);
for(i=0;i<n&&n!=NULL;i++)
{
scanf("%d",&str[i]);
}
for(i=n-1;i>=0;i--)
{
printf("%d ",str[i]);
}
return 0;
}
문자 == 문자 (o)
char c = 't';
if(c=='u') (o)
문자열 == 문자열 (x)
char str[50]= "hello";
if(str=="hello") (x)
*/
/*
#include<stdio.h>
#include<string.h>
int main() {
char s[50]={};
scanf("%s",s);
if(s[0]=='l' && s[1]=='o'&&s[2]=='v'&&s[3]=='e'&&s[4]==NULL) {
printf("I love you.");
}
return 0;
}
*/
/*
#include<stdio.h>
#include<string.h>
int main() {
char str[101]= {};
int i, max=0, h=0;
scanf("%d", &str);
for(i=0; str[i]!=NULL&&str<100; i++) {
if(str[i]=='c'||str[i]=='C')
{
max++;
}
if(str[i]=='c'&&str[i+1]=='C') {
h++;
}
}
printf("%d %d", max,h);
return 0;
}
*/
/*
#include<stdio.h>
#include<string.h>
int main()
{
char str[101]={};
int i, max=0, h=0;
scanf("%s",str);
for(i=0;str[i]!=NULL;i++)
{
if(str[i]=='c'||str[i]=='C')
{
max++;
}
if((str[i]=='c'||str[i]=='C')&&(str[i+1]=='c'||str[i+1]=='C'))
{
h++;
}
else
{
h+=0;
}
}
printf("%d\n%d", max,h);
return 0;
}
*/
/*
#include<stdio.h>
#include<string.h>
int main()
{
char arr[1000000]={};
int i, n;
scanf("%d",&n);
for(i=n;i>=0;i++)
{
scanf("%d",&arr[i]);
}
for(i=0;i>=n;i--)
{
printf("%d",arr[i]);
}
return 0;
}
*/
/*
#include<stdio.h>
#include<string.h>
int main()
{
char arr[1000000]={};
int i, n;
scanf("%d",&n);
for(i=n;i>=0;i++)
{
n/2;
}
for(i=0;i>=n;i--)
{
printf("%d",arr[i]);
}
return 0;
}
*/
/*
#include<stdio.h>
#include<string.h>
int main() {
char s[101]={};
int n=0, i;
gets(s);
for(i=0;s[i]!=NULL;i++)
{
if(s[i]=='l'&& s[i+1]=='o'&&s[i+2]=='v'&&s[i+3]=='e')
{
n++;
}
}
printf("%d", n);
return 0;
}
*/
/*
#include<stdio.h>
#include<string.h>
int main()
{
char s[10]={};
scanf("%s",s);
printf("welcome! %s", s);
return 0;
}
문자열의 길이 : strlen(str)
*/
/*
#include<stdio.h>
#include<string.h>
int main()
{
char s[101]={};
int i,n;
gets(s);
n=strlen(s);
for(i=n-1;i>=0;i--)
{
printf("%c",s[i]);
}
return 0;
}
아스키코드 : 각 문자의 고유 코드 넘버 (이미 약속된)
'a' 97
'b' 98
...
'z'
'A' 65
'B' 66
...
'Z' 90
' ' 32
NULL 0
"hello"
"1010"
str[0] '1'
str[1] '0'
str[2] '1'
str[3] '0'
str[4] NULL
'0' 48
'1' 49
'2' 50
...
'9'
'10' (X) 문자도 아니고, 존재할수없다!!!!!
10 2 100
10 3 1000
10 5 100000
10 500 10000000000000000000.......0000000
어떤 수가 3의배수??
12345678941321567498465가 3의배수인지?
각 자리수의합이 3의 배수인지?
3213112145
#include<stdio.h>
#include<string.h>
int main()
{
//printf("%d",'a');
printf("%c",'t'-32);
}
*/
#include<stdio.h>
int main() {
char s[501]= {};
int i, n,m=0;
scanf("%s",s);
n=strlen(s);
for(i=n-1; n>=0; i--) {
m+=i;
}
if(m/3==0)
{
printf("1");
}
else
{
printf("0");
}
return 0;
}



