#include<stdio.h>
#include<stdlib.h>

void main()
{
long long t,s,x,a,n;
scanf("%lld %lld %lld",&t,&s,&x);

if(t>x)
{
printf("NO\n");exit(0);}

if(x==t){
printf("YES\n");exit(0);}

a=t+s;

if((x-a)%s==0){
printf("YES\n");exit(0);}

n=(x-a)/s+1;

if(x==(a+(n-1)*s+1)){
printf("YES\n");
exit(0);}

printf("NO\n");
exit(0);
}

#include<stdio.h>
int main()
{
    int i,t,m,n,s;
    scanf("%d%d%d",&m,&n,&s);
    t=m;

if(m==s)
printf("YES\n");
else
    {

       for(i=1;;i++)
       {
           m=t+(n*i);

           if(m>=s || (m+1)==s)
            break;

       }
       if(m==s||(m+1)==s)
        printf("YES\n");
       else
        printf("NO\n");

    }

return 0;

}

#include<stdio.h>

main()

{
    double t,s,x,result,result2;
    long long p,q;

    scanf("%lf %lf %lf",&t,&s,&x);
    result=(x-t)/s;
    p=(int)(result);
    result2=(x-t-1)/s;
    q=(int)(result2);
    if(t==x) printf("YES\n");
    else if(t>x) printf("NO\n");
    else if(t==(x-1)) {printf("NO\n");}
    else if(p==result || q==result2)
    {
        printf("YES\n");
    }
    else{printf("NO\n");}
    return 0;
}

#include <stdio.h>
//#include <math.h>
int main(void)
{
	long long int t= 0; //time of first barking
	long long int s= 0; //barking interval
	long long int x= 0; //time of eating
	scanf("%lld", &t);
	scanf("%lld", &s);
	scanf("%lld", &x);

	if(x < t)	printf("NO\n");
	else if( (x-t)%s == 0 )	printf("YES\n");
	else if( x == (t+1) )	printf("NO\n");
	else if( (x-t-1)%s == 0 )	printf("YES\n");
	else	printf("NO\n");

	return 0;
}

#include<stdio.h>
int main()
{
    long t,s,x,m,i=0;
    scanf("%ld %ld %ld",&t,&s,&x);
    m=t;
    while(m<x)
    {
        i++;
        m=t+(i*s);
        if(m>=x)
            break;
        else
            m=t+(i*s)+1;
    }
    if(m==x)
    {
        printf("YES");
    }
    else if(m>x)
    {
        printf("NO");
    }
    return 0;
}

#include<stdio.h>
int main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    if(x>t+1)
    {
        if((x-t)%s==0||(x-t-1)%s==0)
            {
                printf("YES\n");
            }
            else
            {
                printf("NO\n");
            }
            }
            else
            {
                if(x==t)
                    {
                printf("YES\n");
            }
            else
            {
                printf("NO\n");
            }
            }
            return 0;
}

#include <stdio.h>
int main()
{
    int t,s,x;
    scanf("%d%d%d",&t,&s,&x);
    int tmp=x-t;
    if ((tmp%s==0||tmp%s==1)&&tmp>=0&&tmp!=1)
        printf("YES");
    else
        printf("NO");
}

#include<stdio.h>
int main()
{
	int t,s,x;
	scanf("%d %d %d",&t,&s,&x);
	if((x-t)==1||(x-t)<0)
	{
		printf("NO");
		return 0;
	}
	if((x-t)%s==0||(x-t-1)%s==0)
	printf("YES");
	else
	printf("NO");
}

#include<stdio.h>
int main()
{
	long long int t,s,x,a;
	scanf("%I64d %I64d %I64d",&t,&s,&x);
	if(x>=t)
	{
		a=x-t;
	    if(((a%s==0) || ((a-1)%s==0)) && (a-1)!=0)
	    printf("YES");
	    else
	    printf("NO");
	}
	else
	printf("NO");
	return 0;
}

#include <stdio.h>

int main(int argc, char ** argv){
	int t,s,x;
	scanf("%d %d %d",&t,&s,&x);
	int start=t;
	if(start==x){
		printf("%s", "YES");
		return 0;
	}
	while(start<x){
		start+=s;
		if(start==x || (start+1)==x){
			printf("%s", "YES");
			break;
		}

	}
	if(start>x){
		printf("%s","NO");
	}

	return 0;
}

#include<stdio.h>
int main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    if((x >= t && x % s == t % s)||(x > t + 1 && x % s == (t + 1) % s)){
        printf("YES\n");
    }
    else printf("NO\n");
    return 0;
}

#include<stdio.h>
int main()
{
    long long int t,s,x,a;
    scanf("%lld%lld%lld",&t,&s,&x);
    if(t>x){
        printf("NO\n");
    }
    else if(t==x){
        printf("YES\n");
    }
    else if(x==t+1){
        printf("NO\n");
    }
    else {
        a=x-t;
        if(a%s==0||a%s==1){
            printf("YES\n");
        }
        else {
            printf("NO\n");
        }
    }
    return 0;
}

#include<stdio.h>
int main()
{
    long long int x,t,s;
    scanf("%lld%lld%lld",&t,&s,&x);
    x=x-t;
    if(x>=0)
    {
        if(x%s==0||x%s==1&&x!=1)
        printf("YES\n");
    else
        printf("NO\n");
    }
    else
        printf("NO\n");
    return 0;
}

#include<stdio.h>

int main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    if(x>t+1)
    {
        if((x-t)%s==0||(x-t-1)%s==0)
        {
            printf("YES\n");
        }
        else
            printf("NO\n");
    }
    else
    {
        if(x==t)
            printf("YES\n");
        else
            printf("NO\n");
    }
    return 0;
}

#include<stdio.h>
int main()
{
int t,s,x;
while(scanf("%d %d %d",&t,&s,&x)!=EOF)
{
    if(x<t) printf("NO\n");
   else if(x==t+1) printf("NO\n");
   else if((x-t)%s==0||(x-1-t)%s==0)
        printf("YES\n");
    else printf("NO\n");

}
	return 0;
}

#include <stdio.h>
#include<math.h>
int main()
{
    long long int t,s,x,a,b,c,i,j;
    scanf("%lld %lld %lld",&t,&s,&x);
    a=t+s;
    b=a%s;
    c=(a+1)%s;
    i=x%s;
    if(x>a)
    {
        if(i==b || i==c)
        {
            printf("YES");
        }
        else
        {
            printf("NO");
        }
    }
    else
    {
        if (t==x || (t+s)==x)
        {
            printf("YES");
        }
        else
        {
            printf("NO");
        }
    }
    return 0;
}

#include<stdio.h>
int main() {
	int t, s, x; scanf("%d%d%d", &t, &s, &x);
	if (x < t) { printf("NO"); return 0; }
	if ((!((x - t) % s) || !((x - t - 1) % s)) && x != t + 1) printf("YES");
	else printf("NO");
	return 0;
}

 #include <stdio.h>
int main()
{
	int s,t,x,d,i;
	scanf("%d%d%d",&s,&t,&x);
	if(s==x)
	{
	printf("YES\n");
	return 0;
	}
	for(i=1; ;i++)
	{
		s=s+t;
		d=s+1;
		if(d>=x)
		break;
}
if(s==x || d==x){
printf("YES\n");
        }
else{
printf("NO\n");
        }
return 0;
}

#include<stdio.h>
int t,s,x;
int main()
{
    scanf("%d%d%d",&t,&s,&x);
    if(x<t)
    {puts("NO");
    return 0;}
    if((!((x-t)%s)||!((x-t-1)%s))&&x!=t+1)
    puts("YES");
    else
    puts("NO");
    return 0;
}

#pragma warning(disable:4996)
#include <stdio.h>
#include <malloc.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
#define forn(i,n) for (i = 0; i<n; i++)

int lol(const void *x1, const void *x2)
{
	return *(int*)x1 - *(int*)x2;
}

int gcd(int a, int b)
{
	int c;
	while (b)
	{
		c = a % b;
		a = b;
		b = c;
	}
	return a;
}
int main(void)
{
	int a, b, c;
	scanf("%i%i%i", &a, &b, &c);
	c -= a;
	if ((c % b == 0 || c % b == 1) && (c >= b || c == 0))
		printf("YES");
	else
		printf("NO");
	return 0;
}

#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
#include<stdlib.h>
#include<math.h>
#include<stdbool.h>
#include<string.h>
int main() {
	long t, s, x; scanf("%ld%ld%ld", &t, &s, &x);
	long ys = x - t;
	if (ys >= 0) {
		long y = ys % s;
		if (y == 0) {
			puts("YES");
			return 0;
		}

	}
	ys = x - t - 1;
	if (ys >= 0) {
		long y = ys / s;
		if (y >= 1&& ys%s==0)
			puts("Yes");
		else
		{
			puts("NO");
		}
	}
	else
		puts("NO");
	return 0;
}

#include<stdio.h>
main()
{
	long t, s, x;
	scanf("%ld%ld%ld", &t, &s, &x);
	if (x==t || ((x-t)%s==0 && (x-t)>=s)  || ((x-t-1)%s==0 && (x-t-1)>=s))
	printf("YES\n");
	else
	printf("NO\n");
	return 0;
}

#include <stdio.h>

int main()
{
    long long int t, s, x, quotient, i, p;
    scanf("%I64d %I64d %I64d", &t, &s, &x);

    if(s > x){
        if(t == x)
            printf("YES");
        else
            printf("NO");
    }
    else{
        for(i=1;  ; i++){
            p = t + i * s;
            if(p == x || (p + 1) == x){
                printf("YES");
                break;
            }
            else if(p > x){
                printf("NO");
                break;
            }
        }
    }

    return 0;
}

#include<stdio.h>
#include<stdlib.h>
unsigned long int s, t, x;

char series (void)
{
	unsigned long int res=t;
	if (res == x)return 1;
	if (res > x) return 0;
	for (unsigned long int i = 1; i <= 1000000000; i++)
	{
		res = t + i * s;
		if (res == x)return 1;
		if (res > x) return 0;
		res++;
		if (res == x)return 1;
		if (res > x) return 0;
	}

}
int main()
{
	scanf("%d%d%d", &t, &s, &x);
	if (series()) printf("YES");
	if (!series()) printf("NO");
	//getch();
	return 0;
}

#include <stdio.h>
int main(){
    int t,s,x;
    scanf("%i%i%i",&t,&s,&x);
    if( ((x-t)%s==0 || (x-t-1)%s==0) && x!=t+1 && x>=t)
        printf("YES");
    else
        printf("NO");
    return 0-0-0;
}

#include <stdio.h>

int main()
{
   long x, y, z;
   scanf("%d %d %d", &x, &y, &z), z-=x;
   if(z==0 || ((z%y==0 || z%y==1) && z>1))printf("YES");
   else printf("NO");
}

#include<stdio.h>
int main()
{
	int t,s,x,r;
	scanf("%d%d%d",&t,&s,&x);
	r=s+1;
	if(x==t)
	printf("YES");
	else
	{
	if(x<t||(x>t&&x<s))
	printf("NO");
	else
	{
		while(x>=t||x>=r)
		{
			t+=s;
			r=t+1;
			if(x==t||x==r)
			{
				printf("YES");
				break;
			}
		}
		if(x<t)
		printf("NO");
	}
	}
}

#include<stdio.h>
#include<stdlib.h>
unsigned long int s, t, x;

char series (void)
{
	unsigned long int res=t;
	if (res == x)return 1;
	if (res > x) return 0;
	for (unsigned long int i = 1; i <= 1000000000; i++)
	{
		res = t + i * s;
		if (res == x)return 1;
		if (res > x) return 0;
		res++;
		if (res == x)return 1;
		if (res > x) return 0;
	}

}
int main()
{
	scanf("%d%d%d", &t, &s, &x);
	if (series()) printf("YES");
	if (!series()) printf("NO");
	return 0;
}

#include <stdio.h>

int main()
{ long int t,s,x,i,j,temp,flag=0;
 scanf("%u%u%u",&t,&s,&x);
 for(i=0;i<=x;i++)
 {
     temp=(s*i)+t;
     if(temp==x)
     {
         printf("YES");
         flag=1;
         break;
     }
     temp=temp+1;
     if(i>0)

     {if(temp==x)
     {
         printf("YES");
         flag=1;
         break;
     }}
     temp=temp-1;

 }
 if(flag==0)
 {
     printf("NO");
 }
}

#include<stdio.h>

int main()
{
	int t,s,x;
	scanf("%d %d %d",&t,&s,&x);

	if(x==t && x>=t)
	{
		printf("YES");
		return 0;
	}
	if((x-t)%s==0 && x>=(t+s))
	{
		printf("YES");
		return 0;
	}
	if((x-t-1)%s==0 && x>=(t+s+1))
	{
		printf("YES");
		return 0;
	}
	printf("NO");
	return 0;
}

#include<stdio.h>
int main ()
{
    int t,x,s;
    scanf("%d %d %d",&t,&s,&x);
    if(x<t || x==t+1)
        printf("NO\n");
    else if((x-t)%s==0 || (x-t)%s==1)
        printf("YES\n");
    else
        printf("NO\n");
    return 0;
}

#include<stdio.h>
void main()
{	int t,s,x,i,J,k;
	J= 1;
	i = 1;
	scanf("%d %d %d",&t,&s,&x);
	k = t;
	while(k < x)
	{      	k = t + s*J;
		if(i%2 !=0 && i!=1)
		{	J++;
			k++;
		}
		i++;
	}
	if(k == x)
		printf("YES\n");
	else
		printf("NO\n");

}

#include<stdio.h>
int main()
{
  int m,k,l,i,flag=0;
  scanf("%d %d %d",&k,&l,&m);

  for(i=1;m>=k+(i-1)*l;i++)
   {
    if(m==k || m==k+i*l || m==k+i*l+1)

       flag=1;
   }

      if(flag==0)
        printf("NO\n");

      else
       printf("YES\n");

   return 0;
}

#include<stdio.h>

int main()	{
	int t,s,x;
	scanf("%d%d%d",&t,&s,&x);
	if(x<t)		puts("NO");
	else	{
		x-=t;
		if(x ==0 || x>=s){
			x%=s;
			if(x==0 || x==1)	puts("YES");
			else	puts("NO");
		}
		else	puts("NO");
	}
	return 0;
}

#include <stdio.h>
int main()
{
    long long s,x,t;
    scanf("%lld%lld%lld", &t,&s,&x);
    if(x<t||x==t+1)
    {
        printf("NO");
    }
    else if(x==t)
        {
            printf("YES");
            //break;
        }
    else if((x-t)%s==0||(x-t-1)%s==0)
        printf("YES");
    else
        printf("NO");
    return 0;
}

main()
{
    long long i,j,k,l,t,s,x,n;
    scanf("%lld %lld %lld",&t,&s,&x);
    j=0;
    if(t==x)
        printf("YES");
    else
    {
        t=t+s;
        if(x>=t)
        {

            n=(x-t+s)/s;
            if(t+(n-1)*s==x)
            {
                j=1;
                printf("YES\n");
            }
            n=(x-1-t+s)/s;
            if(t+(n-1)*s==(x-1))
            {
                j=1;
                printf("YES\n");
            }
            if(j==0)
                printf("NO\n");
        }
        else
            printf("NO\n");
    }
}

#include<stdio.h>
main()
{
    long long int t,s,x,i;
    int flag=0;
    scanf("%lld",&t);
    scanf("%lld",&s);
    scanf("%lld",&x);
    i=t;
    while(i<=x)
    {
        /*printf("%Ld",x);
        printf("%Ld",t);*/
        if(x==t)
        {
            printf("YES");
            flag=1;
            break;
        }
        i+=s;
        if((x==i || x==(i+1)))
        {
            printf("YES");
            flag=1;
            break;
        }
    }
    if(flag==0)
        printf("NO");
}

#include <stdio.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>

int main() {

     long int t,s,x;
    scanf("%ld %ld %ld",&t,&s,&x);
    if(x==t+1){
        printf("NO");

    }
    else{
    long int temp=(x-t)%s;
        long int te1=(x-t-1)%s;
        if(x==t)
                    printf("YES");
    else if((x-t)>=s && temp==0 )
        printf("YES");
    else if((x-t)>=s && temp==1)
                printf("YES");
     else
        printf("NO");
    }

}

#include <stdio.h>
#include <stdlib.h>

int main()
{
   int t=0,s=0,x=0,n=0,b=0;
   scanf("%d%d",&t,&s);
   scanf("%d",&x);
     if(t>x){
        printf("NO");
        return 0 ;
     }
    n=(x-t);
    int z = (x-t)-1;
    if(n%s==0||z%s==0)
        b=1;
    if(z==0)
      b=0;

      if(b==1)
        printf("YES");
      else
        printf("NO");

    return 0;
}

#include<stdio.h>
#include<stdlib.h>

int main()
{
	long int t, s, x;
	scanf("%ld%ld%ld", &t, &s, &x);

	if(t==x)
		printf("YES\n");

	else
	{

		for(t = t+s; t<=x; t=t+s)
		{
			if( x == t )
			{
				printf("YES\n");
				exit(0);
			}
			else if( x == t+1 )
			{
				printf("YES\n");
				exit(0);
			}
		}

		printf("NO\n");
	}
return 0;
}

#include <stdio.h>

int main() {
    long t, s, x;
    scanf("%I32d %I32d %I32d\n", &t, &s, &x);
    x -= t;
    if (x < 0 || x == 1 || ((x - 1) % s && x % s))
        printf("NO");
    else
        printf("YES");
}

# include <stdio.h>

int main(){
	int t,s,x;
	scanf("%d %d %d",&t,&s,&x);
	int diff = (x-t)%s;
	int quo = (x-t)/s;
	if(quo>=1){
		if(diff==0 || diff==1 ){
			printf("YES\n");
		}else{
			printf("NO\n");
		}
	}
	else{
		if(x==t){
			printf("YES\n");
		}else{
			printf("NO\n");
		}
	}
	return 0;
}

#include<stdio.h>
int main()
{
	long long int t,s,x;
	scanf("%lld %lld %lld",&t,&s,&x);
	//x-t or x-(t+1) should be multiple of s
	if(x<t)
	printf("NO\n");
	else
	{
	if((x-t)%s==0 || ((x-t-1)%s==0 && (x-t)>1))
	printf("YES\n");
	else
	printf("NO\n");
}
	return 0;
}

#include<stdio.h>

int main(void)
{
	long long int t,s,x;
	scanf("%I64d %I64d %I64d",&t,&s,&x);
	if(x<t) {
		printf("NO");
		return 0;
	}
	if(x==(t+1)) {
		printf("NO");
		return 0;
	}
	x-=t;
	x%=s;
	if(x==0) {
		printf("YES");
		return 0;
	}
	if(x==1) {
		printf("YES");
		return 0;
	}
	printf("NO");

	return 0;
}

#include<stdio.h>
#include<string.h>

char ch[20];

int main(void)
{
	long long int s1,s2;
	long long int t,s,x,i,j;
	scanf("%I64d %I64d %I64d",&t,&s,&x);
	if(x==t) {
		printf("YES");
		return 0;
	}
	for(i=1,j=1; ;i+=2,j++) {
		s1=t+j*s;
		s2=s1+1;
		if(s1==x || s2==x) {
			printf("YES");
			return 0;
		}
		if(s2>x) {
			printf("NO");
			return 0;
		}
	}

	return 0;
}

#include<stdio.h>
int main()
{ long int t,s,x,y,z;
	scanf("%ld%ld%ld",&t,&s,&x);

	y=t;
	if(x==t){
		printf("yes");
		return 0;}
	while(x>=y){
		y=y+s;
		z=y+1;
		if(x==y||x==z){
			printf("yes");
			return 0;
		}
	}
	printf("no");
	return 0;
}

#include <stdio.h>

int canEat(int x, int t, int s) {
  if (x < t) return 0;
  if (x == t + 1) return 0;
  if (x % s == t % s) return 1;
  if ((x - t - 1) % s == 0) return 1;
}

int main() {
  long int t, s, x;
  scanf("%ld %ld %ld", &t, &s, &x);
  canEat(x, t, s) ? printf("YES\n") : printf("NO\n");
  return 0;
}

#include <stdio.h>
#include <stdlib.h>

int main()
{
   long long t,s,x;
   scanf("%lld %lld %lld",&t,&s,&x);

   if (((x==t+1)&&(s!=1))||(t>x))
    printf("NO");
   else
    if (((x-t)%s==0)||((x-t)%s==1))
     printf("YES");
    else
     printf("NO");

}

#include<stdio.h>
int main()
{
	int t,s,x,flag=0,i;
	scanf("%d %d %d",&t,&s,&x);
	if(t==x)
		flag=1;
	else
		for(i=1;;i++)
		{
			if(t+i*s==x || t+i*s+1==x)
				flag=1;
			else if(t+i*s>x || t+i*s+1>x)
				break;
		}
	if(flag==1)
		printf("YES\n");
	else
		printf("NO\n");
	return 0;
}

#include<stdio.h>
long long int x[100001];
void quicksort(int first,int last){
    long long int pivot,j,temp,i;

     if(first<last){
         pivot=first;
         i=first;
         j=last;

         while(i<j){
             while(x[i]<=x[pivot]&&i<last)
                 i++;
             while(x[j]>x[pivot])
                 j--;
             if(i<j){
                 temp=x[i];
                  x[i]=x[j];
                  x[j]=temp;
             }
         }

         temp=x[pivot];
         x[pivot]=x[j];
         x[j]=temp;
         quicksort(first,j-1);
         quicksort(j+1,last);

    }
}
int main()
{
    long long int a=0,b=0,c=0,d=0,n=0,t=0,x=0,y=0,z=0,arr[100001],arr1[100001],i,cnt=0,j,k,s;
    scanf("%lld %lld%lld",&t,&s,&x);
    if((((x-t)%s==0||(((x-1-t)%s==0)&&x-1-t>0)))&&(x-t>=0))
    {
        printf("YES\n");

    }
    else
    {
        printf("NO\n");
    }

    return 0;
}

#include<stdio.h>

int main()
{
 int t,s,x;
 scanf("%d%d%d",&t,&s,&x);
 if (x==t+1||x<t)
 printf("NO\n");
 else if ((x-t)%s==0||(x-t-1)%s==0)
 printf("YES\n");
 else
 printf("NO\n");

 return 0;
}

#include<stdio.h>
#include<math.h>
int main(){
   int n,s,x,i;
    scanf("%d%d%d",&n,&s,&x);
  if(n==x){
    printf("YES");}
    else {

      if((x-n)%s==0&&x>n)
        printf ("YES");
      else {

        if((x-n-1)%s==0&&(x>n)&&x>=(n+s)) printf("YES");
        else printf("NO");
      }

    }
  }

#include <stdio.h>
#include <stdbool.h>

int main()
{
	int t, s, x;

	scanf("%d", &t);
	scanf("%d", &s);
	scanf("%d", &x);

	if (x == t || (x >= t + s && (x % s == t % s || x % s == (t + 1) % s )))
		printf("YES\n");
	else
		printf("NO\n");

	return 0;
}

// 1470169088949

#include<stdio.h>
#include<math.h>
int main()
{
  int t,s,x;
  scanf("%d%d%d",&t,&s,&x);
  if(x<t)
  printf("NO");
  else
  {
    int n = x-t;
    if(n==0)
    printf("YES");
    else
    {
      if((n%s==0||n%s==1)&&n>=s)
      printf("YES");
      else
      printf("NO");
    }
  }
}

#include <stdio.h>

int main ()
{
  int t, s, x, n;
  scanf ("%d %d %d", &t, &s, &x);

  n = (x - t) / s;
  if (n == 0) n = 1;

  if      (x < t)              printf("NO");
  else if (x == t)             printf("YES");
  else if (x < t + s * n)      printf("NO");
  else if (x == t + s * n)     printf("YES");
  else if (x == t + s * n + 1) printf("YES");
  else                         printf("NO");

  return 0;
}
// 1470168150868

#include<stdio.h>
#include<string.h>
int main()
{
	long long int t,flag=0,i,s,x;
	scanf("%lld%lld%lld",&t,&s,&x);
	if(x==t)
		flag=1;
	for(i=t+s;i<=x;i+=s)
	{
//		printf("%lld ",y);
		if(x==i || x==i+1)
		{
			flag=1;
			break;
		}
	}
	if(flag==1)
		printf("YES");
	else
		printf("NO");
	return 0;
}

#include<stdio.h>
#include<stdlib.h>
int main()
{
	int t,x,s,i=0;
	scanf("%d%d%d",&t,&s,&x);
	while(t<=x)
	{
		if(x==t+1 && i)
		{
			printf("YES\n");
			return 0;
		}
		if(x==t)
		{
			printf("YES\n");
			return 0;
		}
		i++;
		t+=s;
	}
	printf("NO\n");
	return 0;
}

#include<stdio.h>
int main()
{ int t,s,x,i,d,e;
scanf("%d %d %d",&t,&s,&x);
for(i=0;;i++)
{
d=t+i*s;
e=t+((i+1)*s)+1;
if(d==x ||e==x)
{ printf("YES");
 break;
}
if(d>x)
{ printf("NO");
 break;
}

d=0;
e=0;}
return 0;
}

#include <stdio.h>

int main() {
	int t,s,x,l;
	scanf("%d %d %d",&t,&s,&x);
	l=t;
	while (l <= x) {
		if (t == x) {
			printf("YES\n");
			return 0;
		}
		else if (t+s == x) {
			printf("YES\n");
			return 0;
		}
		else if (t+s+1 == x) {
			printf("YES\n");
			return 0;
		}
		else t = t+s;

		l+=s;
	}

	printf("NO\n");

	return 0;
}

// 1470168683505

#include <stdio.h>
int main()
{
	int t, s, x;
	int flag = 0;
	scanf("%d%d%d", &t, &s, &x);
	if ((x - t) % s == 0 && x>=t) flag = 1;
	if ((x - t - 1) % s == 0 && x > t + 1) flag = 1;
	if (flag == 1) printf("YES\n");
	else printf("NO\n");
	return 0;
}

#include<stdio.h>
int main()
{
    int t , s , x , sum , mod , div , diff,mod1,mod2;
    scanf("%d %d %d",&t,&s,&x);
    sum=(t+s);
    if((x>=t||x<=t)&&(x<=sum)){

        if(x==t)
        {
            printf("YES\n");
        }
        else if(x==sum)
        {
            printf("YES\n");
        }
        else {
            printf("NO\n");
        }
    }
        else if(x>sum)
        {
            mod=sum%s;
            sum+=1;
            mod1=sum%s;
            mod2=x%s;
            if(mod2==mod1||mod2==mod)
            {
                printf("YES\n");
            }
            else{
                printf("NO\n");
            }
        }

    return 0;
}

#include<stdio.h>
int main ()
{
    int t, s,x, sum=0, extra,c;
    scanf("%d %d %d", &t, &s, &x);
    if (t==x)
        printf("YES\n");
    else
    {
        c=(x-t)%s;
        if((c==1 || c==0) && x-t>1)
            printf("YES\n");
        else
            printf("NO\n");
    }

    return 0;
}

#include<stdio.h>
#include<math.h>
#include<string.h>

main()
{
    long int t,s,x,a,b,c;

    scanf("%ld %ld %ld",&t,&s,&x);

    if(x==t)
    {
        printf("YES\n");
    }

   else if(x<t || x<t+s)
    {
        printf("NO\n");
    }

    else
    {
        a=x-t;
        b=a%s;
        if(b==0)
        {
            printf("YES\n");
        }
        else
        {
            a=x-t-1;
            b=a%s;

            if(b==0)
        {
            printf("YES\n");
        }

        else
            printf("NO\n");
        }

    }
    return 0;
}

#include <stdio.h>
int main() {
	long t, s, x;

	scanf("%d %d %d", &t, &s, &x);
	if (t < x && x < t + s) {
		printf("NO");
		return 0;
	}
	if (t == x) {
		printf("YES");
		return 0;
	}
	if (t > x) {
		printf("NO");
		return 0;
	}
	while (t <= x) {
		t += s;
	}
	t -= s;
	if (t == x || t + 1 == x) printf("YES");
	else printf("NO");

	return 0;
}

#include<stdio.h>
int main()
{
    long long t,s,k,flag=1,gabbar=1,p;
    scanf("%I64d%I64d%I64d",&t,&s,&k);
    p=k-t-1;
    if((k-t)%s==0&&k>=t){printf("YES\n");gabbar=0;}
    else if((k-t-1)%s==0&&((k-t)%s==0&&k>=t)){printf("YES\n");flag=0;gabbar=0;}

    else if((p)%s==0&&(flag)&&p!=0&&k>=t)printf("YES\n");
    else if(gabbar) printf("NO\n");

    return 0;
}

#include <stdio.h>

unsigned char c(unsigned int t,unsigned int s,unsigned int x);

int main() {
	unsigned int t;
	unsigned int x;
	unsigned int s;
	scanf("%d %d %d",&t,&s,&x);
	int i;
	//for(i=0;i<100;i++) {
	//printf("%d ",i);
	if(c(t,s,x)) {
		printf("YES");
	} else {
		printf("NO");
	}
	//	printf("\n");
	//}
	return 0;
}

unsigned char c(unsigned int t,unsigned int s,unsigned int x) {
	if((x-t)%s==0 && x>=t) {
		return 1;
	} else {
		if ((x-t-1)%s==0 && x>t+1) {
			return 1;
		} else {
			return 0;
		}
	}
}

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int main(){

  char INPUT[1000];
  char FINAL[4]= "";
  int s;
  int TIME;
  int TOTAL;

  fgets(INPUT, sizeof(INPUT), stdin);
  sscanf(INPUT, "%d %d %d", &TOTAL, &s, &TIME );

  if(TIME == TOTAL + s || TIME == TOTAL){
     TOTAL = TIME;
     goto end;
  }
  TOTAL = TOTAL + s;

    while (TIME > TOTAL){
         TOTAL++;

      if (TOTAL == TIME) {
          break;
      }
      TOTAL = TOTAL + s - 1;

      if (TOTAL == TIME) {
	      break;
      }

    }
   end: { if (TOTAL == TIME){
      strncpy(FINAL,"YES", 3);
    }
    else {
      strncpy(FINAL,"NO", 2);
    }
    fputs(FINAL, stdout);
    return 0;
    }
}

#include <stdio.h>

int main(void)
{
    long t, s, x;
	scanf("%ld%ld%ld", &t, &s,&x);

    int is = 0;

    if (x == t) is = 1;
    else if (x > t+1)
        is = (x-t)%s == 0 || (x-t)%s == 1;

    puts(is ? "YES" : "NO");

	return 0;
}

#include<stdio.h>
int main()
{
    int a,b,c,i;
    scanf("%d%d%d",&a,&b,&c);
    if(a==c)
    {
        printf("YES\n");
        return 0;
    }
    for(i=a+b; i<=c; i+=b)
        if(i==c||i+1==c)
        {
            printf("YES\n");
            return 0;
        }
    printf("NO\n");
    return 0;
}

#include<stdio.h>
int main()
{
int t,s,x;
scanf("%d%d%d",&t,&s,&x);
if(x<t)
printf("NO");
else if(((x-t)%s==0|(x-t)%s==1)&&(x>=(t+s)|x==t))
printf("YES");
else
printf("NO");
return 0;
}

    #include <assert.h>
    #include <limits.h>
    #include <math.h>
    #include <stdbool.h>
    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>
    #define lli long long int
    #define li long int

    int main()
    {

        #ifndef ONLINE_JUDGE
        freopen("input.txt", "r", stdin);
        freopen("output.txt", "w", stdout);
        #endif
        long int t,s,x;
        scanf("%ld%ld%ld",&t,&s,&x);
        if(x-t<0)
        {
            printf("NO"); return 0;
        }
        if(((x-t)%s==0||(x-t-1)%s==0)&&(x!=t+1))
            printf("YES\n");
        else
            printf("NO\n");
        return 0;
    }

#include<stdio.h>
int main()
{
    int t,s,x,r;//r-remainder
    scanf("%d%d%d",&t,&s,&x);
    r=abs(x-t);
    if(t>x){
        printf("NO\n");
    }
    else if((r!=1&&r%s==1)||r%s==0){
        printf("YES\n");
    }
    else{
        printf("NO\n");
    }
    return 0;
}

#include<stdio.h>
int main()
{
    long long int x,t,s;
    scanf("%lld%lld%lld",&t,&s,&x);
    x=x-t;
    if(x>=0)
    {
        if(x%s==0||x%s==1&&x!=1)
        printf("YES\n");
    else
        printf("NO\n");
    }
    else
        printf("NO\n");
    return 0;
}

#include <stdio.h>
int main()
{
    long long int t, i, x, total, n1, n2;
    scanf("%lld %lld %lld", &t, &i, &x);

    n1 = t%i;
    n2 = (t+1)%i;

    if(x==t) printf("YES");
    else if(x>t+1 && (x%i==n1 || x%i == n2)) printf("YES");
    else printf("NO");
    return 0;
}

#include <stdio.h>

int main()
{
    int a,b,c,s,t,x;

    scanf("%d %d %d",&s,&t,&x);

    if (s-x==0)
        printf("YES\n");

        else if( x>=t && x>=s){
            a=x-s;
            if(a<0)
            a=-a;
            if(a%t==0 && (a/t)!=0)
                printf("YES");
            else if((a-1)%t==0 && ((a-1)/t)!=0)
              printf("YES");
            else
                printf("NO");

        }
        else
            printf("NO");

    return 0;
}

#include<stdio.h>
int main()
{
	int t, s, k, x;
	scanf("%d %d %d", &t, &s, &x);
	if(x==t)
	{
		printf("YES");
	}
	else if(x<t)
	{
		printf("NO");
	}
	else
	{
		k=x-t;
		if(k%s==0)
		{
			printf("YES");
		}
		else
		{
			k-=1;
			if(k!=0 && k%s==0)
			{
				printf("YES");
			}
			else
			{
				printf("NO");
			}
		}
	}
}

#include<stdio.h>
int main()
{
    int i,j,k,l,t,s,x,m;
    scanf("%d %d %d",&t,&s,&x);
    if(x<=t+1)
    {
        if(x==t)
        {
            printf("YES");
        }
        else
        {
            printf("NO");
        }
    }
    else
    {
        if((x-t)%s==0||(x-t-1)%s==0)
        {
            printf("YES");
        }
        else
        {
            printf("NO");
        }
    }

}

#include <stdio.h>
//#include <math.h>
int main(void)
{
	int t= 0; //time of first barking
	int s= 0; //barking interval
	int x= 0; //time of eating
	scanf("%d", &t);
	scanf("%d", &s);
	scanf("%d", &x);

	if(x < t)	printf("NO\n");
	else if( (x-t)%s == 0 )	printf("YES\n");
	else if( x == (t+1) )	printf("NO\n");
	else if( (x-t-1)%s == 0 )	printf("YES\n");
	else	printf("NO\n");

	return 0;
}

#include<stdio.h>
main()
{
    long long int t,s,x;
    scanf("%lld %lld %lld",&t, &s, &x);
    if((t<=x && (x%s)==(t%s)) || ((2*t+1<=x) && (x%s)==((t+1)%s))) printf("YES");
    else printf("NO");
}

    #include <assert.h>
    #include <limits.h>
    #include <math.h>
    #include <stdbool.h>
    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>
    #define lli long long int
    #define li long int

    int main()
    {

        #ifndef ONLINE_JUDGE
        freopen("input.txt", "r", stdin);
        freopen("output.txt", "w", stdout);
        #endif
        long int t,s,x;
        scanf("%ld%ld%ld",&t,&s,&x);
        if((x-t)>0&&(t+s<x)&&((x-t)%s==0||(x-t-1)%s==0))
            printf("YES\n");
        else
            printf("NO\n");
        return 0;
    }

#include<stdio.h>
int main()
{
	int t,s,x,i,flag=0;
	scanf("%d%d%d",&t,&s,&x);
	for(i=1;i<600000000;i++)
		if(x==t+i*s||x==t+i*s+1||x==t)
			flag=1;
		if(flag==1) printf("YES\n");
		else printf("NO\n");
		return 0;
}

#include <stdio.h>
#include <string.h>

int main()
{

  int t,s,x ;
  scanf("%d%d%d",&t,&s,&x);
  if ((x-t)%s==0 && (x-t)!=0  )
  {
      printf("yes %d",(x-t)%s);
  }
  else if((x-t-1)%s==0  )
  {
     printf("YES");
  }
else printf("NO");
    return 0 ;
}

#include<stdio.h>
int main()
{
    long long t,s,i,x,a,c=0,b;
    scanf("%I64d%I64d%I64d",&t,&s,&x);
    for(i=0;i<x/2;i++){
        a=t+(s*i);
        b=a+1;
        if(a==x||(b==x&&i!=0)){
            c=1;
            break;
        }
        else{
            c=0;
        }
    }
    if(c==1){
        printf("YES\n");
    }
    else if(c==0){
        printf("NO\n");
    }
    return 0;
}

#include<stdio.h>
int main()
{
	long long int t,s,x;
	scanf("%lld %lld %lld",&t,&s,&x);
	//x-t or x-(t+1) should be multiple of s

	if((x-t)%s==0 || ((x-t-1)%s==0 && (x-t)>1))
	printf("YES\n");
	else
	printf("NO\n");
	return 0;
}

#include <stdio.h>
int main()
{
    int t,s,x,p,q,i;
    scanf("%d %d %d",&t,&s,&x);
    if(x<t)
    {
        printf("NO");
    }
    else if(x==t)
    {
        printf("YES");
    }
    else if(x>t)
    {
        p=t;

        for(i=1; i<=10000; i++)
        {
            p=p+s;
            q=p+1;
            if(p==x || q==x)
            {
                printf("YES");
                break;
            }
            else if(p>x && q>x)
            {
                printf("NO");
                break;
            }
        }
    }
}

#include <stdio.h>
int main() {
  int s,t,x;
  scanf("%d%d%d",&t,&s,&x);
  printf("%s\n",x==t+1||(x-t)%s>=2?"NO":"YES");
  return 0;
}

//gcc 5.4.0

#include  <stdio.h>

int main(void)
{
    long t,s,x;
    scanf("%ld",&t);
    scanf("%ld",&s);
    scanf("%ld",&x);
    if(x==t+1){
        printf("NO");
        return 0;
    }
    if(((x-t)%s)==0||((x-t)%s==1)){
        printf("YES");
    }
    else{
        printf("NO");
    }
    return 0;
}

#include <stdio.h>

int main(int argc, const char * argv[]) {
    int t,s;
    int x;
    scanf("%d %d %d",&t,&s,&x);
    if(x==t){
        printf("YES");
    }
    else if(x>=(t+s)){
        if((x-t)%s==0||(x-t-1)%s==0)
            printf("YES");
    }
    else
        printf("NO");
}

#define _CRT_SECURE_NO_DEPRECATE
#include <stdio.h>

#define mprint(x) printf("%d\n",x)

//#define DEBUG
#define LOOP_START
#define LOOP_END

#ifdef DEBUG
#undef LOOP_START
#undef LOOP_END
#define LOOP_START while(1){
#define LOOP_END }
//#define UNLOCK //
#endif

int main(){
	int t, s, x;
	LOOP_START
	scanf("%d %d %d", &t, &s, &x);
	//mprint(t);
	//mprint(s);
	//mprint(x);
	//printf("----------------\n");
	x = x - t;
	#ifdef DEBUG
		mprint(x);
		mprint(x % s);
		mprint(-3 % 2);
		mprint(-9295072 % 2);
	#endif
	if ( ( x>-1 && (x-1)>-1) && (x % s == 0 || ((x - 1)>0 && (x - 1) % s == 0) || x == 0))
		printf("YES\n");
	else printf("NO\n");
	LOOP_END

	return 0;
}

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int main(){

  char INPUT[1000];
  char FINAL[4]= "";
  int s;
  int TIME;
  int TOTAL;

  fgets(INPUT, sizeof(INPUT), stdin);
  sscanf(INPUT, "%d %d %d", &TOTAL, &s, &TIME );

    while (TIME > TOTAL){
      TOTAL = TOTAL + s - 1;
      if (TOTAL == TIME) {
	      break;
      }
      TOTAL++;
      if (TOTAL == TIME) {
          break;
      }
    }
    if (TOTAL == TIME){
      strncpy(FINAL,"YES", 3);
    }
    else {
      strncpy(FINAL,"NO", 2);
    }
    fputs(FINAL, stdout);
    return 0;
}

#define _CRT_SECURE_NO_DEPRECATE
#include <stdio.h>
#define mprint(x) printf("%d\n",x)

	int main(){
		int t, s, x;
		//while (1){
			scanf("%d %d %d", &t, &s, &x);
			//mprint(t);
			//mprint(s);
			//mprint(x);
			//printf("----------------\n");
			x = x - t;
			//mprint(x);
			//mprint(x % s);
			//mprint(3 / 2);

			if (x % s == 0 || (x - 1) % s == 0 || x==0)
				printf("YES\n");
			else printf("NO\n");

		//}

		return 0;
	}

#include<stdio.h>
#include<conio.h>
int main()
{
	 long int t,s,x,p;
	 scanf("%ld%ld%ld",&t,&s,&x);
	 if(x<t+s&&x!=t)
	 {
 		printf("NO");
 		return 0;
 	}else if(x==t)
 	{
 	    printf("YES");
 	}else if(x>t+s)
 	{
 		p=x-t;
 		if(p%s==0)
 		{
 		printf("YES");
 		return 0;
 		}
 		else if((p-1)%s==0)
 		{
 			printf("YES");
 		}else printf("NO");
 	}

}

#include<stdio.h>
main()
{
	int t,s,x,i,j;
	scanf("%d%d%d",&t,&s,&x);
	if(t+1==x)
	{
		printf("NO");return 0;
	}
	if(x<t)
	{
		printf("NO");return 0;
	}
	if(x%s==t||x%s==t+1)
	printf("YES");
	else
	printf("NO");
}

#include <stdio.h>
int main()
{
	int t, s, x;
	int flag = 0;
	scanf("%d%d%d", &t, &s, &x);
	if ((x - t) % s == 0) flag = 1;
	if ((x - t - 1) % s == 0 && x != t + 1) flag = 1;
	if (flag == 1) printf("YES\n");
	else printf("NO\n");
	return 0;
}

#include <stdio.h>

int main(void) {
	// your code goes here
	int t,s,k;
	scanf("%d%d%d",&t,&s,&k);
	if(k<(s+t)&&k>t)
{
    printf("NO\n");return 0;
}
	int rem=(k-t)%s;
	if(rem==0||rem==1||k==t)
	printf("YES\n");
	else
	printf("NO\n");
	return 0;
}

#include<stdio.h>
int main()
{
long long int t,s,x;
scanf("%lld%lld%lld",&t,&s,&x);
if((x-t)%s==0)
printf("YES");
else if((x-t-1)%s==0)
{
if((x-t-1)/s)
printf("YES");
else
printf("NO");
}
else
printf("NO");
return 0;
}

#include<stdio.h>
int main()
{
int t,s,x;
while(scanf("%d %d %d",&t,&s,&x)!=EOF)
{
    if(x==t+1) printf("NO\n");
   else if((x-t)%s==0||(x-1-t)%s==0)
        printf("YES\n");
    else printf("NO\n");

}
	return 0;
}

#include <stdio.h>
int main(){
    int t,s,x;
    scanf("%i%i%i",&t,&s,&x);
    if( ((x-t)%s==0 || (x-t-1)%s==0) && x>t+1)
        printf("YES");
    else
        printf("NO");
    return 0-0-0;
}

#include <stdio.h>
int main(){
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    x=x-t;
    if(x%s==0)
        printf("YES");
    else if(x!=1 && (x-1)%s==0)
        printf("YES");
    else
        printf("NO");
    return 0;
}

#include<stdio.h>
int main()
{
    int t,s,x,r;
    scanf("%d%d%d",&t,&s,&x);
    r=x-t;
    if(r%s==1||r%s==0){
        printf("YES\n");
    }
    else{
        printf("NO\n");
    }
    return 0;
}

#include<stdio.h>
#include<math.h>
int main()
{
	int t,s,x,z;
	scanf("%d %d %d",&t,&s,&x);
	int d=(x-t)/s;
	d=d*2;
	while(d>0){

		if(d==1)
			z=t+(d)*s;
		else if(d%2==0)
			z=t+(d/2)*s;
		else
			z=t+1+(d/2)*s;
		if(x==z)
			{printf("YES");return 0;}
		if(x<z)
			{printf("NO");return 0;}
		d++;
	}
	printf("NO");
	return 0;

}

#include<stdio.h>
int main(){

 unsigned long long int t,s,x,sum=0,sum1=0,i;
 scanf("%llu %llu %llu",&t,&s,&x);
 for(i=1;i<=x;i++){
    sum=t+i*s;
    sum1=t+i*s+1;
    if(t==x||sum==x||sum1==x){
        printf("YES");
        break;
    }
    if(sum>x||sum1>x){
        printf("NO");
        break;
    }
 }

return 0;

}

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main()
{
    long long t,s,x,i,a,b,c,d,j,k;double p,q;
    scanf("%I64d %I64d %I64d",&t,&s,&x);
    if(t==x){printf("YES");}
    else{
    a=fabs(x-t);b=fabs(a-1);
    p=a/s;q=b/s;
    c=p;d=q;
    j=c/p;k=d/q;
    if(j==1||k==1)
    {
        printf("YES");
    }
    else{printf("NO");}}

}

#include<stdio.h>
int main()
{
    int t,s,x;
    scanf("%d%d%d",&t,&s,&x);
    if(x>t+1){
        if((x-t)%s==0||(x-t-1)%s==0)
        {
            printf("YES");
        }
        else
            printf("NO\n");
    }
    else{
        if(x==1)
            printf("YES\n");
        else
            printf("NO\n");
    }
    return 0;
}

#include <stdio.h>
//#include <math.h>
int main(void)
{
	int t= 0; //time of first barking
	int s= 0; //barking interval
	int x= 0; //time of eating
	scanf("%d", &t);
	scanf("%d", &s);
	scanf("%d", &x);
	int k=s;

	if(x == t) printf("YES\n");
	else
	{
		for (int i = 0; i < 1000; ++i) //1000 is a randomly chosen value
		{
			if(x%(t+s) == 0  ||  x%(t+s+1) == 0)
				{printf("YES\n"); break;}
			if((t+s) > x)
				{printf("NO\n"); break;}

			s= s+k;
		}
	}

	return 0;
}

#include<stdio.h>
int main()
{
	int t,s,x;
	scanf("%d %d %d",&t,&s,&x);
	if(x<t)
		printf("NO\n");
	else if(x<s)
	{
		if(t%x==0)
			printf("YES\n");
		else
			printf("NO\n");
	}
	else
	{
		if(t%(x%s)==0 || (t+1)%(x%s)==0)
			printf("YES\n");
		else
			printf("NO\n");
	}
	return 0;
}

#include<stdio.h>
int main()
{
	int a,b,c,i,f=0;
	scanf("%d%d%d",&a,&b,&c);
	for(i=1;i<c&&f==0;i++)
		if(c==(a+i*b)||c==(a+i*b+1)||c==a)
			f=1;
	if(f==0)
		printf("NO");
	else
		printf("YES");
	return 0;
}

#include <stdio.h>
int main() {
	long t, s, x;

	scanf("%d %d %d", &t, &s, &x);
	if (t < x && x < t + s) {
		printf("NO");
		return 0;
	}
	if (t == x) {
		printf("YES");
		return 0;
	}
	while (t <= x) {
		t += s;
	}
	t -= s;
	if (t == x || t + 1 == x) printf("YES");
	else printf("NO");

	return 0;
}

#include<stdio.h>
#include<string.h>

char ch[20];

int main(void)
{
	int a[105];
	int t,s,x,i,j;
	scanf("%d %d %d",&t,&s,&x);
	a[0]=t;
	if(x==t) {
		printf("YES");
		return 0;
	}
	for(i=1,j=1;i<1000000001;i+=2,j++) {
		a[i]=t+j*s;
		a[i+1]=a[i]+1;
		if(a[i]==x || a[i+1]==x) {
			printf("YES");
			return 0;
		}
		if(a[i]>x) {
			printf("%d",i);
			printf("NO");
			return 0;
		}
	}

	return 0;
}

#include<stdio.h>
int main()
{
    int a,s,d,p;
    while(scanf("%d%d%d",&a,&s,&d)!=EOF)
    {
      p=(d-a)%s;

     if((p==0||(p==1&&d!=(a+1))&&a<=d))
printf("%Yes\n");
else printf("No\n");
    }
}

#include<stdio.h>
main()
{
	int t,s,x,i,j;
	scanf("%d%d%d",&t,&s,&x);
	if(t+1==x)
	{
		printf("NO");return 0;
	}
	if(x<t)
	{
		printf("NO");return 0;
	}
	if(x%s==t||x%s==t+1)
	printf("YES");
	else
	printf("NO");
}

#include<stdio.h>
int main()
{
	long long int t,s,x;
	scanf("%lld %lld %lld",&t,&s,&x);
	//x-t or x-(t+1) should be multiple of s

	if((x-t)%s==0 || ((x-t-1)%s==0 && (x-t)>1) && x>t)
	printf("YES\n");
	else
	printf("NO\n");
	return 0;
}

#include <stdio.h>

int main() {
  long int t, s, x;
  scanf("%ld %ld %ld", &t, &s, &x);
  if (x % s == t % s || (x != t + 1 && (x - t - 1) % s == 0)) {
    printf("YES\n");
  } else {
    printf("NO\n");
  }
  return 0;
}

#include<stdio.h>

int main()
{
    int t,s,x;
    scanf("%d%d%d",&t,&s,&x);
    if(x>t){
    if((x-t)%s==0||(x-t-1)%s==0){
        printf("YES\n");
    }
    else printf("NO\n");
    }
    else{
        if(x==t) printf("YES\n");
        else printf("NO\n");
    }
    return 0;
}

#include<stdio.h>
int main()
{
    long long i,j,k,n,t,s,x;
    scanf("%lld%lld%lld",&t,&s,&x);
    n=(x/s)*s+(x%s);
    k=x/s;
    i=k*s+t;//printf("%d %d",i,n);
    if(k==0&&n==i)printf("YES");//return 0;}
    else if(k==0&&n!=i) printf("NO");//return 0;}
    else if(i==n||i+1==n)
        printf("YES");
    else
        printf("NO");
}

#include<stdio.h>
#include<math.h>
#include<ctype.h>
int main()
{

    long long a,b,c;
    scanf("%lld%lld%lld",&a,&b,&c);
    if(a==c )
    {
        printf("YES\n");
        return 0;;
    }
    if(a==c-1){
        printf("NO\n");
        return 0;;
    }
    int f=c-a-1;
    int  s=c-a;
           if (f%b==0 || s%b==0)
               printf("YES\n");
    else
        printf("NO\n");
    return 0;;
}

#include<stdio.h>
main()
{
    long long int t,s,x;
    scanf("%I64d%I64d%I64d",&t,&s,&x);
    x=x-t;
    if(x==0)
        printf("YES");
        else if((x==1)&&(s!=1))
            printf("NO");
    else if((x%s==0)||(x%s==1))
    printf("YES");
    else printf("NO");

}

#include<stdio.h>
int main()

{
       long long int s,t,x,i,sum=0;

	scanf("%lld%lld%lld",&t,&s,&x);

/*	for(i=1;i<=100;i++)
	  {
              if(x==t || x==t+i*s || x==t+i*s+1)
        {
               sum=sum+1;
		break;
        }
          }
*/
	int y;
	y=(x-t)%s;
//	z=(x-t-1)%s;
	if(y==0 || y==1)
	printf("YES");

	//if(sum==1)
	//{printf("YES");}
	else{printf("NO");}
	return 0;}

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main()
{
    long long t,s,x,i,a,b;
    scanf("%I64d %I64d %I64d",&t,&s,&x);
    i=x/s;

        if(i==0){ a=t+s*i;b=a;}
        else{
        a=t+s*i;b=a+1;}

          if(x==a||x==b)
          {
              printf("YES");
          }

      else{printf("NO");}

}

#include<stdio.h>
#include<stdlib.h>

void main()
{
long long t,s,x,a,n;
scanf("%lld %lld %lld",&t,&s,&x);

if(t>=x)
{
printf("NO\n");exit(0);}

if(x==t){
printf("YES\n");exit(0);}

a=t+s;

if((x-a)%s==0){
printf("YES\n");exit(0);}

n=(x-a)/s+1;

if(x==(a+(n-1)*s+1)){
printf("YES\n");
exit(0);}

printf("NO\n");
exit(0);
}

#include<stdio.h>

int main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);

        if(x==t || x%t==0) printf("YES\n");
        else printf("NO\n");

    return 0;
}

#include <stdio.h>

int main(){
    long t,s,x;
    scanf("%d%d%d",&t,&s,&x);
    x = x -t;
    if(x%s==0) printf("YES");
    else if(x%s==1 && x/s!=0) printf("YES");
    else printf("NO");

}

#include<stdio.h>

int main()
{
	long t,s,x,p,q;
	scanf("%lu %lu %lu",&t,&s,&x);
	p=(x-t)%s;
	q=(x-t-1)%s;
	if(x==t||p==0||q==0)
	{
		printf("YES");
	}
	else
	{
		printf("NO");
	}

	return 0;
}

#include <stdio.h>

int main(void){

  int t,s,x;

  scanf("%d %d %d", &t, &s, &x);

  if(t==x){
    printf("YES\n");
    return 0;
  }

  if(t+1==x){
    printf("NO\n");
    return 0;
  }

  int remainder=x-t;

  if(remainder%s==0 || remainder%s==1){
    printf("YES\n");
    return 0;
  }

  printf("NO\n");

}

#include<stdio.h>
int main(){
	int t,s,x,i,flag=0;
	scanf("%d %d %d",&t,&s,&x);
	if(t==x){
		printf("YES");
		return 0;
	}
    if(x-t-1!=0)
	if((x-t)%(s)==0 || (x-t-1)%(s)==0){
		printf("YES");
	}

	else{
		printf("NO");
	}

	return 0;
}

#include<stdio.h>
int main()
{
    int t,x,s;
    while(scanf("%d%d%d",&t,&x,&s)!=EOF)
    {
        if(s-t==0)
            printf("Yes\n");
        else if(0<s-t&&s-t<x)
            printf("No\n");
        else if((s-t)%x==0||(s-t-1)%x==0)
            printf("Yes\n");
    }
    return 0;
}

#include<stdio.h>

int main(void){
	long long t = 0, s = 0, x = 0, a = 0, b = 0;
	int con = 0;
	scanf("%d %d %d",&t,&s,&x);
	if(t != x){
		if(x % s == 3 || x % s == 4 && x > s){
			printf("YES\n");
			con++;
		}
		if(con == 0){
			printf("NO\n");
		}
	}
	else {
		printf("YES\n");
	}
}

#include <stdio.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>

int main() {

     long int t,s,x;
    scanf("%ld %ld %ld",&t,&s,&x);
    if(x==t+1){
        printf("NO");

    }
    else{
    long int temp=(x-t)%s;
    if(temp==0 || temp==1)
        printf("YES");
    else
        printf("NO");
    }

}

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main()
{
	long long int t , s, x,n,k,z;
	int y=0;
	int a=0;
	scanf("%lld %lld %lld",&t,&s,&x);
	for (n=1;n<(x/2+1);n++)
	{
		(k=(t+(n-1)*s));
		if (x==k)
		{
			y++;
			break;
		}

		z=((t+1+s) + ((n-1)*s));
		if (x==z)
		{
			a++;
			break;
		}
	}

		if (a==1 || y==1)
	{
		printf("yes");
	}
	else
	{
		printf("no");
	}

}

#include <stdio.h>
int main()
{
    long long int t, i, x, total, n;
    scanf("%lld %lld %lld", &t, &i, &x);
    n = t%i;
    if(x==t) printf("YES");
    else if(x>t+1 && (x%i<(n+2))) printf("YES");
    else printf("NO");
    return 0;
}

#include<stdio.h>

int main(){

	int x ,t ,s;
	scanf("%d%d%d",&t ,&s ,&x);
	if((x-t)%s==0)
	   printf("YES\n");
	else if((x-t-1)%s==0)
	   printf("YES\n");
	   else printf("NO\n");

	   return 0;
}

#include <stdio.h>
//#include <math.h>
int main(void)
{
	long long int t= 0; //time of first barking
	long long int s= 0; //barking interval
	long long int x= 0; //time of eating
	scanf("%lld", &t);
	scanf("%lld", &s);
	scanf("%lld", &x);

	if(x < t) printf("NO\n");
	else if( (x-t)%s == 0  ||  (x-t-1)%s == 0 ) printf("YES\n");

	return 0;
}

#include<stdio.h>
int main()
{
    long long int t,s,n,a,b,i,flag;
    while(scanf("%lld%lld%lld",&t,&s,&n)!=EOF)
    {
        if(t==n)
            {
                printf("YES\n");
                }
        else
            {
                flag=0;
        for(i=1;i<=s;i++)
        {
                a=t+i*s;
                b=t+i*s+1;
                if(a==n)
                {
                    flag=1;
                    break;
                }
                else if (b==n)
                {
                    flag=2;
                     break;
                }

            }
            if(flag==1 || flag==2)
            {
                printf("YES\n");
            }
            else
            {
                printf("NO\n");
            }
            }
        }

    return 0;
}

#include<stdio.h>
int main(){
    long long int t,s,x,i,b,a;
    scanf("%lld %lld %lld",&t,&s,&x);
    if(x==t){
        printf("YES");
        return 0;
    }
    for(i=1; ;i++){
        b=s+t;
        a=b+1;
        if(a>=x){
            break;
        }
    }
    if(b==x||a==x){
        printf("YES");
    }
    else{
        printf("NO");
    }
    return 0;
}

#include<stdio.h>
int main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    if(t==x)
    {
        printf("YES");
    }
    int i,j,y=1,temp=0;
    for(i=t+s,j=s;;)
    {
        if(i>x)
        {
            temp=1;
            break;
        }
        if(i==x)
        {
            temp=0;
            break;
        }
        if(y==0)
        {
            i+=s-1;
            y=1;
        }
        else if(y==1)
        {
            i+=1;
            y=0;
        }
    }
    if(temp==0) {
        printf("YES");
    }
    else if(temp==1){
        printf("NO");
    }
    return 0;
}

#include <stdio.h>
int main()
{
	long long int t,s,x;
	scanf("%I64d %I64d %I64d",&t,&s,&x);
	if(x<t)
	{
		printf("NO");
	}
	else if(x==t)
    {
    	printf("YES");
    }
	else
	{
		if(((t-x)%s==0||(t-x)%s==1)&&x!=t+1)
		{
			printf("YES");
		}
		else
		{
			printf("NO");
		}
	}
	return 0;
}

#define _CRT_SECURE_NO_DEPRECATE
#include <stdio.h>

#define mprint(x) printf("%d\n",x)

//#define DEBUG
#define LOOP_START
#define LOOP_END

#ifdef DEBUG
#undef LOOP_START
#undef LOOP_END
#define LOOP_START while(1){
#define LOOP_END }
//#define UNLOCK //
#endif

int main(){
	int t, s, x;
	LOOP_START
	scanf("%d %d %d", &t, &s, &x);
	//mprint(t);
	//mprint(s);
	//mprint(x);
	//printf("----------------\n");
	x = x - t;
	//mprint(x);
	//mprint(x % s);
	//mprint(3 / 2);

	if (x % s == 0 || ((x - 1)!=0 && (x - 1) % s == 0) || x == 0)
		printf("YES\n");
	else printf("NO\n");
	LOOP_END

	return 0;
}

#include <stdio.h>
main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    if(x>=t && (x-t)%s ==0 || x+1>=t && (x-1-t)%s==0)
    printf("Yes");
    else
    printf("No");
}

#include<stdio.h>

int main()
{
    long long int t,s,b,c,d,f;
    double a,x,e;
    scanf("%lld %lld %lf",&t,&s,&x);
    a=x/s;
    d=a;
    e=a-d;
    f=e+1;
    b=d*s+t;
    c=b+1;
    //printf("%lf %lld %lf\n",a,d,e);
    if(d==0 && x==b)
    {
        printf("YES\n");
    }
    else  if(e==0 && d>0)
    {
        b=d*s;
        c=b+1;
        if(x==b || x==c)
            printf("YES\n");
        else
            printf("NO\n");
    }

    else if(d>0)
    {
        if(x==b || x==c)
            printf("YES\n");
        else
            printf("NO\n");
    }
    else
        printf("NO\n");
    return 0;
}

#include<stdio.h>
int main ()
{
    int t,x,s;
    scanf("%d %d %d",&t,&s,&x);
    if(x<t || x==t+1)
        printf("NO\n");
    else if((x-t)%s==0 || (x-t)%s==1)
        printf("YES\n");
    return 0;
}

#include<stdio.h>
int main(){
	long t,s,x,i,flag=0;
	scanf("%ld %ld %ld",&t,&s,&x);
	if(t==x){
		printf("YES");
		return 0;
	}
    if(x-t-1!=0 && (x-t-1)>=0){
		if((x-t)%(s)==0 || (x-t-1)%(s)==0){
			printf("YES");
		}
	}
	else{
		printf("NO") ;
	}

	return 0;
}

#include <stdio.h>
#include <stdlib.h>

int main()
{
    int t,s,x;
    scanf("%d %d %d",&t,&s,&x);
    if(x-t==0 || (x-t)%s==0 || x-t-s==0 || ((x-t-1)%s==0 && x-t-1!=0)) printf("YES\n");
    else printf("NO\n");
    return 0;
}

#include <stdio.h>

int main()
{
    int a,b,c,s,t,x;

    scanf("%d %d %d",&s,&t,&x);

    if (s-x==0)
        printf("YES\n");

        else if( x>=t && x>=s){
            a=x-s;
            if(a<0)
            a=-a;
            if(a%t==0)
                printf("YES");
            else if((a-1)%t==0)
              printf("YES");
            else
                printf("NO");

        }
        else
            printf("NO");

    return 0;
}

#include <stdio.h>

int main()
{
	long t, s, x;

	scanf("%ld %ld %ld", &t, &s, &x);

	x -= t;
	t = 0;

	if ((x % s == 1) && (x / s > 0) || (x % s == 0))
		puts("YES");
	else
		puts("NO");

	return 0;
}

#include<stdio.h>
int main()
{
    long long int t,s,x,d,e,n,a=0;
    scanf("%lld %lld %lld",&t,&s,&x);
    n=0;
    while((n+1)*s+t+1<=x||n*s+t<=x)
    {
        d=n*s+t-x;
        e=(n+1)*s+t-x+1;
        if(d==0||e==0)
        {
            printf("no");
        }
        else
        {
            a++;
        }
        n++;
    }
if(a!=0)
printf("yes");
else
return 0;
return 0;
}

#include<stdio.h>
main()
{
    long long int t,s,x,n;
    scanf("%lld %lld %lld",&t,&s,&x);
    n=x-t;
    if(n%s==0) printf("YES");
    else if((n-1!=0) && (n-1)%s==0) printf("YES");
    else printf("NO");
}

#include <stdio.h>
#include <stdlib.h>

int main()
{
    int t, s, x;
    scanf("%d %d %d", &t, &s, &x);
    if ((x-t)%s == 0 && ((int)(x-t)/s) > 0){
        printf("YES");
        return 0;
    }
    if ((x-t)%s == 1 && ((int)(x-t)/s) > 0){
        printf("YES");
        return 0;
    }
    printf("NO");
    return 0;
}

#include<stdio.h>
int main()
{
	int t,s,x;
	scanf("%d%d%d",&t,&s,&x);
	if (((x-t)% s == 0)||(((x-t-1)% s==0)&&(x-t-1>0))) printf("YES");
	else printf("NO");
	return 0;
}

#include <stdio.h>
int main()
{
    int t, i, x, total;
    scanf("%d %d %d", &t, &i, &x);
    if(x==t) printf("YES");
    else if(x>t+1 && (x%i<(t+2))) printf("YES");
    else printf("NO");
    return 0;
}

#include<stdio.h>

int main()
{
    long long int t,s,x,a,b,c;
    scanf("%lld %lld %lld",&t,&s,&x);
    a=x/s;
    b=a*s+3;
    c=b+1;
   // printf("%lld %lld\n",a,b);
    if(a==0)
    {
        if(x==b)
            printf("YES\n");
        else
            printf("NO\n");
    }
    else if(a>0)
    {
        if(x==b || x==c)
            printf("YES\n");
        else
            printf("NO\n");
    }
    else
        printf("NO\n");
    return 0;
}

#include<stdio.h>

int main()
{
    int t,s,x,i,temp,vagshesh;
    scanf("%d%d%d",&t,&s,&x);
    temp=x-t;
    vagshesh=temp%s;
    if(vagshesh==0 || vagshesh==1 && (x-t)!=1 && t<=x)
        printf("YES\n");
    else
        printf("NO \n");

    return 0;
}

#include <stdio.h>
#include <stdlib.h>

int main()
{
	int x, s, t;

	scanf("%d%d%d", &t, &s, &x);

	if (t+1 != x && ((x-t)%s == 0 || (x-t-1)%s == 0)) printf("YES");
	else printf("NO");
}

#include <stdio.h>

unsigned char c(unsigned int t,unsigned int s,unsigned int x);

int main() {
	unsigned int t;
	unsigned int x;
	unsigned int s;
	//printf("%d",4%10); return 0;
	scanf("%d %d %d",&t,&s,&x);
	if(c(t,s,x)) {
		printf("YES");
	} else {
		printf("NO");
	}
	return 0;
}

unsigned char c(unsigned int t,unsigned int s,unsigned int x) {
	if(((x%s==t) || ((x-1)%s==t)) && (x>=t+s)) {
		return 1;
	} else {
		return 0;
	}
}

#include <stdio.h>
#include <stdlib.h>

int main()
{
   int t=0,s=0,x=0,n=0,b=0;
   scanf("%d%d",&t,&s);
   scanf("%d",&x);
   n =(x-t);
   if(n%s==0||(n-1)%s==0)
          b=1;
   if(n<0)
       b=0;

   if(b == 1)
    printf("YES");
   else
    printf("NO");

    return 0;
}

#include<stdio.h>
int main(){
    long long int t,s,x,i,b;
    int f=0;
    scanf("%I64d %I64d %I64d",&t,&s,&x);
    if(t==x)
        printf("YES");
    else{
        for(i=1,b=t+s*i;b+1<=x;i++){
            b=t+s*i;
            //printf("%d %d ",b,b+1);
            if(x==b+1||x==b)
                f=1;
        }
        if(f==1)
            printf("YES");
        else
            printf("NO");
    }
}

#include <stdio.h>
int main()
{
    int t,s,x,i;
scanf("%d %d %d",&t,&s,&x);
i=t;

if((((x-i)%s)==0)&&((x-i)!=0))
printf("YES");
else if((((x-i-1)%s)==0)&&((x-i-1)!=0))
printf("YES");
else if(i==x)
printf("YES");
else
printf("NO");

}

#include<stdio.h>
int main()
{
    int a,s,d,p;
    while(scanf("%d%d%d",&a,&s,&d)!=EOF)
    {
      p=(d-a)%s;
      if(p==0||(p==1&&d>2*a))
         printf("Yes\n");
         else printf("No\n");
    }
}

#include<stdio.h>
int barks(unsigned long long int t,unsigned long long int s, unsigned long long int x)
{   int i;
    int bark=0;
    for(i=0;bark<x;i++)
        {   bark=t+i*s;
            printf("%d\n",bark);
             if(bark==x)
                return 0;
            bark++;
            printf("%d\n",bark);
            if(bark==x)
                return 0;
        }
    return 1;
}
int main()
{   unsigned long long int t,s,x,y;
    scanf("%llu %llu %llu",&t,&s,&x);
        y=barks(t,s,x);
    if(y==0)
        printf("YES.");
    else
        printf("NO");
}

    #include <assert.h>
    #include <limits.h>
    #include <math.h>
    #include <stdbool.h>
    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>
    #define lli long long int
    #define li long int

    int main()
    {

        #ifndef ONLINE_JUDGE
        freopen("input.txt", "r", stdin);
        freopen("output.txt", "w", stdout);
        #endif
        long int t,s,x;
        scanf("%ld%ld%ld",&t,&s,&x);
        if((x-t)>0&&((x-t)%s==0||(x-t-1)%s==0))
            printf("YES\n");
        else
            printf("NO\n");
        return 0;
    }


#include <stdio.h>
#include <Windows.h>
int main()
{
float n,m,res;
scanf("%f%f",&n,&m);
if (m==1 && n==1)
	res = 1;
else
	res = (1+(n-1)*(m-1)/(n*m-1))/n;
printf("%f",res);
return 0;
}

#include <stdio.h>
#include <string.h>
#include <stdbool.h>

#define clr(ar) memset(ar, 0, sizeof(ar))
#define read() freopen("lol.txt", "r", stdin)

int n, m;
double binomial[1010][1010];

void Pregenerate(){
    int i, j;
    for (i = 0; i < 1010; i++){
        for (j = 0; j <= i; j++){
            if (i == j || j == 0) binomial[i][j] = 1;
            else binomial[i][j] = (binomial[i - 1][j] + binomial[i - 1][j - 1]);
        }
    }
}

int main(){
    Pregenerate();
    int i, j, k, l;

    while (scanf("%d %d", &n, &m) != EOF){
        int r = (n * m);

        double res = 0.0;
        for (i = 1; i <= n; i++){
            double x = (1.0 * i) / (1.0 * n);
            double p = (x * x);

            k = m, l = r;
            for (j = 1; j <= i; j++, k--, l--){
                double y = (1.0 * k) / (1.0 * l);
                p *= y;
            }

            p *= binomial[n][i];

            k = r - m;
            for (j = i + 1; j <= n; j++, k--, l--){
                double y = (1.0 * k) / (1.0 * l);
                p *= y;
            }
            res += p;
        }
        res = res * n;

        res += 1e-12;
        printf("%0.9lf\n", res);
    }
    return 0;
}

#include <stdio.h>
#include <Windows.h>
int main()
{
float m,n,res;
scanf("%f%f",&m,&n);
res = (1+(n-1)*(m-1)/(n*m-1))/n;
printf("%f",res);
return 0;
}

#include <stdio.h>
int main()
{
int m,n;
float res;
scanf("%d%d",&m,&n);
res = (1+(n-1)*(m-1)/(n*m-1))/n;
printf("%f",&res);
return 0;
}

#include <stdio.h>
#include <Windows.h>
int main()
{
float m,n,res;
scanf("%f%f",&m,&n);
if (n=1) res = 1;
else
res = (1+(n-1)*(m-1)/(n*m-1))/n;
printf("%f",res);
return 0;
}

#include <stdio.h>
int main()
{
int m,n;
double res;
scanf("%d%d",&m,&n);
res = (1+(n-1)*(m-1)/(n*m-1))/n;
printf("%d",&res);
return 0;
}

#include <stdio.h>
#include <Windows.h>
int main()
{
float m,n,res;
scanf("%f%f",&m,&n);
if (n==1)
	res = 1;
else
	res = (1+(n-1)*(m-1)/(n*m-1))/n;
printf("%f",res);
return 0;
}

#include<stdio.h>
int main()
{
double n,m;
while(scanf("%lf%lf",&n,&m)!=EOF)
printf("%.16lf\n",1.0/n+((n-1)*(m-1))/(n*(n*m-1)));
return 0;
}

#include <stdio.h>
#include <string.h>
#include <stdbool.h>

#define clr(ar) memset(ar, 0, sizeof(ar))
#define read() freopen("lol.txt", "r", stdin)

int n, m;
long double binomial[1010][1010];

void Pregenerate(){
    int i, j;
    for (i = 0; i < 1010; i++){
        for (j = 0; j <= i; j++){
            if (i == j || j == 0) binomial[i][j] = 1;
            else binomial[i][j] = (binomial[i - 1][j] + binomial[i - 1][j - 1]);
        }
    }
}

int main(){
    Pregenerate();
    int i, j, k, l;

    while (scanf("%d %d", &n, &m) != EOF){
        int r = (n * m);

        long double res = 0.0;
        for (i = 1; i <= n; i++){
            long double x = (1.0 * i) / (1.0 * n);
            long double p = (x * x);

            k = m, l = r;
            for (j = 1; j <= i; j++, k--, l--){
                long double y = (1.0 * k) / (1.0 * l);
                p *= y;
            }

            p *= binomial[n][i];

            k = r - m;
            for (j = i + 1; j <= n; j++, k--, l--){
                long double y = (1.0 * k) / (1.0 * l);
                p *= y;
            }
            res += p;
        }
        res = res * n;

        printf("%0.9Lf\n", res);
    }
    return 0;
}


#include<stdio.h>

int main(void)
{

    unsigned long long int x;
    scanf("%llu",&x);

    if(x==2)
        printf("2");
    else
    printf("1");

    return 0;
}

#include<stdio.h>
int main()
{
    int v;
    scanf("%d",&v);
    if(v==2)
        printf("2");
    else
        printf("1");
    return 0;
}

#include<stdio.h>
int main(){
int n;
scanf("%d",&n);
if(n==2){
printf("2");
}else{
printf("1");
}

}

#include<stdio.h>
int main(){
   long int n;
    scanf("%ld",&n);
    if(n == 2)printf("2");
    else
    printf("1");
}

#include <stdio.h>
int main()
{
int n;
scanf("%d",&n);
if(n!=2)
printf("1");
else
printf("2");
return 0;
}

#include<stdio.h>
int main()
{
	int n;
	scanf("%d", &n);
	if (n == 2)
	{
		printf("2\n");
	}
	else
	{
		printf("1\n");
	}
	 return 0;
}

#include<stdio.h>
int main()
{
    long long int n;
    scanf("%lld",&n);
    if(n>2||n==1)
      printf("1");
    else
        printf("2");
}

#include <stdio.h>

int number;

int main ()
{
	//freopen ("cf.in","r",stdin),freopen("cf.out","w",stdout);
	scanf ("%d",&number);
	if (number!=2)
	puts ("1");
	else
	puts ("2");
}

#include <stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
long long cmpfunc (const void * a, const void * b) {
   return ( *(long long*)a - *(long long*)b );
}

int main(void){

long long int test,i,j,n,count,flag=0,o1=0,o2=0,b1,x,m,l,max,sum2,min,f,c,r,o,sum1,sum=0,y,a,b,count1=0,a2,b2;

scanf("%lld",&n);
if(n==2){
    printf("2");
}else{
     printf("1");
}
return 0;
}

#include <stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
long long cmpfunc (const void * a, const void * b) {
   return ( *(long long*)a - *(long long*)b );
}

int main(void){

long long int test,i,j,n,count,flag=0,o1=0,o2=0,b1,x,m,l,max,x1,y1,k,sum2,min,f,r,o,sum1,sum=0,y,count1, a[26]={0};
char a1[100000];
scanf("%lld",&n);
if(n==2 || n==1){
    printf("%lld",n);
}else{
    printf("1");
}
return 0;
}

#include <stdio.h>
int main() {
    long long v;
    scanf("%I64d",&v);
    if (v==2) {
        printf("%d",2);
    } else {
        printf("%d",1);
    }
    return 0;
}

#include <stdio.h>

int main(){
    int a;
    scanf("%i",&a);
    if(a==2)
    printf("2");
    else
    printf("1");
}

#include<stdio.h>
int main()
{
	int v;
	scanf("%d",&v);
	if(v==2)
	{
		printf("2\n");
	}
	else
	{
		printf("1\n");
	}
	return 0;
}

#include<stdio.h>
int main()
{
    int n,x,y,z;
    scanf("%d",&n);
    for(y=0;y<n;y++)
    {
        if(n-1==1 || n-1==0){
            printf("%d",n);
            break;
        }

        else if(n%(n-y)!=0)
        {
            //z=n-y;
            printf("%d",y);
            break;
        }
    }
    return 0;
}

#include <stdio.h>

int main(void)
{
 int v;
 scanf("%d", &v);
 if(v==2)
 {
     printf("2");
 }
 else
 {
 printf("1");
}
return 0;
}

#include<stdio.h>
#include<math.h>

int main()
{
    int n;

    scanf("%d",&n);

    if(n==2)
    {
        printf("2");
    }
    else
    {
        printf("1");
    }

    return 0;
}

#include<stdio.h>

/*divisible(int n,int x){
    if(n%x==0){return 1;}
    else{return 0;}
}*/
int main(){
 long v,n,x;
 scanf("%ld",&v);
 n=v;
/* for(long i=1;i<=n;i++){
  if(divisible(n,i)==0){
 x=i;
  }
if(n-x<n && n-x>0){
n=n-x;}
}*/
if(n==2){printf("2");}

else{
 printf("1");}
return 0;
}

#include<stdio.h>

int main()

{
    int n,i;

    scanf("%d",&n);

    while(n>2)
    {
          for(i=2;i<n;i++)
            if((n%i)!=0)
            n=n-i;
            if(n==2)
                n=1;
    }

    printf("%d",n);
}

#include<stdio.h>

int main()
{
   int n,k=1;
   scanf("%d",&n);
   if(n==2)
    k=2;
   printf("%d\n",k);
}

#include<stdio.h>
int main()
{
    long long int v;
    scanf("%lld",&v);
    if(v==1)
        printf("%d",1);
    else if(v==2)
        printf("%d",2);
    else if(v>2)
        printf("%d",1);
    return 0;
}

#include <stdio.h>
int main()
{
int n,x=0,i=1;
scanf("%d",&n);
if(n<=2)
{
for(i=1;i<n;i++)
{
  if(n%i!=0)
{
  x=i;
}
else
{
  x=x;
}
}
}
else
{
	for(i=n-1;i<n;i++)
{
  if(n%i!=0)
{
  x=i;
}
else
{
  x=x;
}
}
}

  printf("%d",n-x);
  return 0;
}

#include<stdio.h>//not acc
int main()
{
    int n,x;
    scanf("%d",&n);
    if(n==1)
    {
        printf("%d\n",n);
    }
    else if(n==2)
    {
        printf("%d",n);
    }
    else if(n>2)
    {
      int x=1;
      printf("%d\n",x);
    }
    return 0;
}

#include<stdio.h>
int main()
{
    int a;
    scanf("%d",&a);
    if(a==2)
        printf("2\n");
    else
    printf("1\n");
}

#include<stdio.h>
int main()
{
// a program by lepusarcticus - Ashutosh Pande
// codeforces avito cool challenge 2018
long long int n,m;
scanf("%I64d",&n);
if (n>=1&&n<=1000000000) //constraints
{
if (n==2)
printf("2");
else
printf("1");
}
return 0;
}

#include <stdio.h>

int main()
{
    long long int a;
    scanf("%I64d", &a);
    if(a == 2)
        printf("2");
    else
        printf("1");
    return 0;
}

#include<stdio.h>
int main()
{
int n;
scanf("%d",&n);
	if(n==2)
	{
		printf("2");
	}
	else
	{
		printf("1");
	}
	return 0;
}

#include<stdio.h>
int main()
{
int n;
scanf("%d",&n);
if(n==2)
{
printf("2");
}
else
{
printf("1");
}
}

#include<stdio.h>
int main()
{
 int n;
 scanf("%d",&n);
 if(n==2){
     printf("2");
 }
 else{
     printf("1");
 }
 return 0;
}

#include<stdio.h>
int main()
{
   int x,n,i,r,s;
    scanf("%lld",&n);

    if(n==2)
    {
        printf("2\n");
    }
    else
        {

                        printf("1\n");

        }

}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    if(n==2)
        printf("2\n");
    else
        printf("1\n");
    return  0;
}

#include<stdio.h>
#include<string.h>
int main()
{
    int i,j,k,l,n,t,d,x;
    scanf("%d",&n);
    if(n!=2)
    {
    printf("1");
    }
    else
    {
      printf("2");
    }
    return 0;
}

#include <stdio.h>
int main(){
	int n;
	scanf("%d",&n);
	if (n>2){
		printf("%d",n-(n-1));
	}
	else if(n==2){
		printf("%d",2);
	}
	else if (n==1){
		printf("%d",1);
	}
	return 0;
}

#include <stdio.h>
int main()
{
    long long int n;
    scanf("%I64d", &n);
    if (n==2)
        printf("2");
    else
        printf("1");
    return 0;
}

#include<stdio.h>
int main(){
int m;
while(scanf("%d",&m)==1){
if(m==2){printf("2\n");}
else{printf("1\n");}}
return 0;}

#include<stdio.h>
int main(){
    int a;
scanf("%d",&a);
if(a==2){printf("2");}
else printf("1");
}

#include<stdio.h>
int main()
{
int n;
scanf("%d",&n);
if(n!=2)
{
n=n-(n-1);
}
printf("%d",n);
}

#include <stdio.h>
int main()
{
    int v,n;
    scanf("%d",&v);
    n=v-v+1;
    if(v==2)
    printf("%d",v);
    else
    printf("%d",n);
    return 0;
}

#include<stdio.h>
int main()
{
    long long int n;
   scanf("%I64d",&n);
   if(n==2) printf("2");
   else printf("1");
}

#include<stdio.h>
int main()
{
    int a,b,s,i;
    scanf("%d",&a);
    if(a==2)
        printf("2\n");
    else
        printf("1\n");

    return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    if(n==2) printf("2");
    else
    printf("1");
}

#include<stdio.h>
int main()
{
	int n,i;
	scanf("%d",&n);
	for(i=n-1;i>0;i--)
	{
		if((n%i)!=0)
		{
			printf("%d",(n-i));
			return 0;
		}
	}
	printf("%d",n);
	return 0;
}

#include<stdio.h>
int main()
{
    long long x;
    scanf("%lld",&x);
    if(x!=2)
    printf("1");
    else if(x=2)
    printf("2");
}

#include<stdio.h>
int main()
{
int n,x,v;
scanf("%d",&v);
n=v;
x=n-1;
while((x<n)&&(x>0))
{
if((n%x)!=0)
{
n=n-x;
}
x--;
}

printf("%d",n);
return 0;
}

#include<stdio.h>
int main(){
   int n;
    scanf("%d",&n);
   if(n!=2){
   printf("%d",1);}
    else{printf("%d",2);}
    return 0;
}

#include<stdio.h>
int main()
{
	int n;
	scanf("%d",&n);

	if(n==2)
	{
		printf("%d",2);
	}
	else
	{
		printf("%d",1);
	}

	return 0;
}

#include<stdio.h>
int main()
{
    int x,y;
    scanf("%d",&x);
    if(x==0)
        printf("0\n");
        else if(x==2)
            printf("2\n");
    else printf("1\n");

return 0;
}

#include <stdio.h>

int main()
{
    int n,i=1;
    scanf("%d",&n);
    if(n!=2)
    printf("1");
    else
    printf("2");
}

#include<stdio.h>
int main()
{
	int n,v=2;
	scanf("%d",&n);
	if(n==2)
	{
		printf("2\n");
	}
	else printf("1\n");
}

#include <stdio.h>

int main()
{
      int n;
      scanf("%d",&n);
      if (n==2){printf("2");}
      else {printf ("1");}
      return 0;
}

#include<stdio.h>

int main()
{
    int n;
    scanf("%d",&n);
    if((n-1)==1)
        printf("%d\n",n);
    else
        printf("%d\n",n-(n-1));
    return 0;
}

#include<stdio.h>

int main(){
     long long int n;
    scanf("%lld",&n);

    if(n == 2){
        printf("2");
    }
    else{
        printf("1");
    }

    return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    if(n==2)
    {
        printf("2");
    }
    else
    {
        printf("1");
    }
    return 0;
}

#include<stdio.h>
int main(){
    long long int n,x,s;
    scanf("%lld",&n);
    if(n==2){
            printf("%lld\n",n);
            return 0;
            }
    /*while(1){
            if(n==1||n==0)break;
     s=n/2;
     n=n-(s+1);
    }*/
    if(n%2==0||n==1)
    printf("1\n");
    else if(n%2!=0)
        printf("1\n");
    return 0;
}

#include<stdio.h>
int main(){
   int t=0,i=1,n=0;
   scanf("%d",&n);
   if(n>2||n==1)printf("%d",1);
   else printf("%d",n);
}

#include <stdio.h>

int main() {
    long int v,n,i,x;
    scanf("%ld",&v);
    n=v;
    for(i=n-1;i>0;i--)
    {
        if(i<n)
        {
        if(n%i!=0)
        n=n-i;
        i=n-1;
        }

    }
    printf("%ld",n);
	//code
	return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    if(n==2)
        printf("2\n");
    else
    printf("1\n");
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    if(n==2){
      printf("2\n");
    }
    else
    printf("1\n");
    return 0;
}

#include<stdio.h>
int main(){
	int n;
	scanf("%d", &n);
	if(n>0&&n!=2)
		printf("1");
	else if(n==0)
		printf("0");
	else if(n==2)
		printf("2");
	else
		printf("-1");
	return 0;
}

#include <stdio.h>

int main(int argc, char **argv)
{int x;
	scanf("%d",&x);
	if (x==2){
	printf("%d ",2);}
	else{
	printf("%d ",1);
	}
	return 0;
}

#include<stdio.h>
int main()
{
      long long int n;
      scanf("%lli", &n) ;

        if(n==2)
        {
        	printf("2\n") ;
       }
        else
        {
        	 printf("1\n") ;
       }
      return 0;
}

#include <stdio.h>

int main() {
    long int v,n,i,x;
    scanf("%ld",&v);
    n=v;
    for(i=1;i<n;i++)
    {
        if(n%i!=0)
        n=n-i;
    }
    printf("%ld",n);
	//code
	return 0;
}

#include <stdio.h>

int main()
{
      int n;
      scanf("%d",&n);
      if (n=2){printf("2");}
      else {printf ("1");}
      return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    printf("1");
}

#include<stdio.h>
int main(){
	int n;
	scanf("%d", &n);
	if(n>0||n==2)
		printf("1");
	else if(n==0)
		printf("0");
	else if(n==2)
		printf("2");
	else
		printf("-1");
	return 0;
}

#include<stdio.h>
int main(){
    long long int n,x,s;
    scanf("%lld",&n);
    while(1){
            if(n==1||n==0)break;
     s=n/2;
     n=n-(s+1);
    }
    printf("%lld\n",n);
    return 0;
}

#include<stdio.h>
int main()
{
    int a,b,s,i;
    scanf("%d",&a);
    if(i==2)
        printf("2\n");
    else
        printf("1\n");

    return 0;
}

#include<stdio.h>

int main()
{
    int n;
    scanf("%d",&n);
    printf("%d\n",n-(n-1));
    return 0;
}

#include<stdio.h>
int main()
{
    int n,x,i;
    scanf("%d",&n);
    while(n>2){
        for(i=2;i<n;i++){
            if(n%i!=0)n=n-i;
        }
    }
    printf("%d",n);
}

#include <stdio.h>
int main() {
	int n;
	scanf ("%d",&n);
if(n>2){
	printf("%d",n-(n-1));
}
if(n==2) {
	printf("%d",2);
}
	return 0;

}

#include<stdio.h>
int main(){
    int a;
scanf("%d",&a);
printf("1");
}

#include <stdio.h>

int main()
{
    char n[100];

    scanf("%s",n);
   if(n==1)
   {
       printf("1");
   }else{
       if((long long int) n %2==0)
       {
          printf("1");
       }else{
       printf("2");
   }}

    return 0;
}

#include <stdio.h>

int main()
{
    char n[100];

    scanf("%s",n);
   if(n==1)
   {
       printf("1");
   }else{
       if((long long int) n %2==0)
       {
          printf("1");
       }else{
       printf("0");
   }}

    return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    printf("1\n");
    return  0;
}

#include <stdio.h>

int main(){
    long long int v;
    scanf("%lld", &v);
    if(v>=3)
        printf("1\n");

    return 0;
}

#include<stdio.h>

int main()

{
    int n;

    scanf("%d",&n);

    printf("1");
}

#include <stdio.h>
int main()
{
    int v,n;
    scanf("%d",&v);
    n=v-v+1;
    printf("%d",n);
    return 0;
}

#include<stdio.h>
int main(){
int a;
scanf("%d",&a);
if(a!=2){printf("1\n");}
else{printf("1\n");}
return 0 ;
}

#include <stdio.h>
int main(){
    int test;
    scanf("%d", &test);
    while(test){
        int n,x,y,d, check=1, flag=0, count=0;
        scanf("%d %d %d %d", &n, &x, &y, &d);
        check=x;
        if(x%2!=0 && d%2!=0){
            while(1){
                if(flag==0) x+=d;
                else x-=d;
                if(x>n){
                    x=check;
                    flag=1;
                    count=0;
                    continue;
                }
                if(x<=1){
                    flag=0;
                }
                count++;
                if(x==y){
                    printf("%d\n", count);
                    break;
                }

            }
        }

        test--;
    }
    return 0;
}

#include<stdio.h>
int main()
{
    int v,t,x,y;
    scanf("%d",&v);
    for(x=1;x<v;x++)
    {
        if(v%x!=0)
        t=v-x;

    }
    if(v==1)
    t=1;

    printf("%d",t);
}

#include<stdio.h>
int main ()
{
    int n;
    scanf("%d",&n);
    if(n==0)
    {
        printf("0\n");

    }
    else if(n>2 || n==1)
    {
        printf("1\n");
    }
}

#include<stdio.h>
int main()
{
int a;
scanf("%d",&a);
printf("%d",1);
return 0;
}

#include <stdio.h>
int main(){
	int n;
	scanf("%d",&n);
	if (n>2){
		printf("%d",n-(n-1));
	}
	else if(n=2){
		printf("%d",2);
	}
	else if (n=1){
		printf("%d",1);
	}
	return 0;
}

#include<stdio.h>

int main()
{
   int n;
   scanf("%d",&n);
   printf("%d\n",1);
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    printf("1");
    return 0;
}

#include <stdio.h>
int main() {
	int n;
	scanf ("%d",&n);

	printf("%d",n-(n-1));
	return 0;

}

#include<stdio.h>
int main(){
    int n;
    scanf("%d",&n);
    printf("1");

}

#include <stdio.h>
#include <string.h>
int main()
{
      int l;
      //char s[25];
      scanf("%d",&l);
      //l=strlen(s);
      if(l>2)
      {
          printf("1");
      }
      else
      {
          printf("2");
      }

      return 0;
}

#include <stdio.h>

int main(void) {
	int n,i=0;
	scanf("%d",&n);
    i=n-(n-1);
    printf("%d",i);
	return 0;
}

#include<stdio.h>
int main()
{
    long long int v;
    scanf("%d",&v);
    if(v==1)
        printf("%d",1);
    else if(v==2)
        printf("%d",2);
    else
        printf("%d",1);
    return 0;
}

#include <stdio.h>

int main()
{
    char n[100];

    scanf("%s",n);
   if(n==1)
   {
       printf("1");
   }else{
       if( atoi(n) %2==0)
       {
          printf("1");
       }else{
       printf("0");
   }}

    return 0;
}

#include<stdio.h>
int main()
{
    long long int n,i,j;
    scanf("%lld",&n);
    j=n;
    for(i=1;i<=j;i++)
    {

        if(n%i!=0)
        {
            n=n-i;
                if(n<i)
                {
                    break;
                }

        }

    }
    printf("%lld",n);

    return 0;
}

#include<stdio.h>
#include<string.h>
int main()
{
    int i,j,k,l,n,t,d,x;
    scanf("%d",&n);
    for(i=1;i<n;i++)
    {
        if(n%i!=0)
        {
            n=n-i;
        }
    }
    printf("%d",n);
    return 0;
}

#include<stdio.h>
int main()
{
    int n,x;
    scanf("%d",&n);

        printf("%d\n",n);

    return 0;
}

#include <stdio.h>

int main()
{
    int n;
    scanf("%d",&n);
        printf("1\n");

    return 0;
}

#include <stdio.h>
#include <string.h>
int main()
{
      int l;
      //char s[25];
      scanf("%d",&l);
      //l=strlen(s);
      printf("1");
      return 0;
}

#include<stdio.h>
int main()
{
    int a,b,s,i;
    scanf("%d",&a);
    if(a==1||a==2)
        printf("1\n");
    else
    {
        for(i=2;i<a;i++)
        {
            if(a%i!=0)
            {
                a=a-i;
            }
            if(a<=0)
                break;
            else
                s=a;
        }
        printf("%d\n",s);
    }
    return 0;
}

#include <stdio.h>
int main() {
	int n;
	scanf ("%d",&n);
if(n>2){
	printf("%d",n-(n-1));
}
if(n==2) {
	printf("%d",2);
}
if(n=1) {
	printf("%d",1);
}
	return 0;

}

#include<stdio.h>
int main(){
   int n;
    scanf("%d",&n);
   printf("%d",1);
    return 0;
}

#include<stdio.h>
int main()
{
    int n,x;
    scanf("%d",&n);
    if(n==1)
    {
        printf("%d\n",n);
    }
    else
    {
      x=n%(n-1);
      printf("%d\n",x);
    }
    return 0;
}

#include<stdio.h>

int main()
{
int n,x;
int i=1;
int c=0;
scanf("%d",&n);
while (i<=n)
{
if(n%i==0)
{
}
else
{
n=n-i;
if(n==1)
{
}
}
i++;
}
printf("%d\n",n);
return 0;
}

#include<stdio.h>
int main()
{
int n;
scanf("%d",&n);
	if(n==2)
	{
		printf("0");
	}
	else
	{
		printf("1");
	}
}

#include <stdio.h>
int main()
{ int n;
  scanf("%d",&n);
  printf("1\n");
  return 0;
}

#include <stdio.h>

int main(void)
{
 int v;
 scanf("%d", &v);

 printf("1");

return 0;
}

#include<stdio.h>
int main()
{
// a program by lepusarcticus - Ashutosh Pande
// codeforces avito cool challenge 2018
long long int n,m;
scanf("%I64d",&n);
if (n>=1&&n<=1000000000) //constraints
{
for (m=1;m<=n;m++)
{
if (n%m!=0) //divisibility test
{
n-=m; // subtracting divisors
}
}
printf("%I64d",n);
}
return 0;
}

#include<stdio.h>
int main()
{
	int t,n;
	scanf("%d",&t);
	while(t--)
	{
		scanf("%d",&n);
		if(n==2)
		{
			printf("2");
		}
		else
		{
			printf("1");
		}
	}

	return 0;
}

#include<stdio.h>

int main()
{
int n,x;
int i=1;
int c=0;
scanf("%d",&n);
while (i<=n)
{
if(n%i==0)
{
}
else
{
n=n-i;
if(n==1)
{
}
if(i==2)
{
n=n-1;
}
}
i++;
}
printf("%d\n",n);
return 0;
}

#include<stdio.h>

divisible(int n,int x){
    if(n%x==0){return 1;}
    else{return 0;}
}
int main(){
 long v,n,x;
 scanf("%ld",&v);printf("%ld\n",v);
 n=v;
 for(long i=1;i<=n;i++){
  if(divisible(n,i)==0){
 x=i;
  }
if(n-x<n && n-x>0){
n=n-x;}
}
 printf("%ld",n);
return 0;
}

#include<stdio.h>

int main()
{
    int n;
    scanf("%d",&n);
    printf("%d\n",n-(n-1));
    return 0;
}

#include<stdio.h>
int main()
{
	int n,i;

	for(i=n-1;i>0;i--)
	{
		if((n%i)!=0)
		{
			printf("%d",(n-i));
			return 0;
		}
	}
	printf("%d",n);
	return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    printf("1\n");
    return 0;
}

#include "stdio.h"
#include "string.h"

int main()
{
	int i;
	scanf("%d",&i);
	printf("1");
}

#include<stdio.h>
int main(){
	int n;
	scanf("%d", &n);
	if(n>0)
		printf("1");
	else if(n==0)
		printf("0");
	else if(n==2)
		printf("2");
	else
		printf("-1");
	return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    printf("1");
    return 0;
}

#include<stdio.h>
int main(){
    long long int n,x,s;
    scanf("%lld",&n);
    if(n==2){
            printf("%lld\n",n);
            return 0;
            }
    while(1){
            if(n==1||n==0)break;
     s=n/2;
     n=n-(s+1);
    }
    printf("%lld\n",n);
    return 0;
}

#include <stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
long long cmpfunc (const void * a, const void * b) {
   return ( *(long long*)a - *(long long*)b );
}

int main(void){

long long int test,i,j,n,count,flag=0,o1=0,o2=0,b1,x,m,l,max,sum2,min,f,c,r,o,sum1,sum=0,y,a,b,count1=0,a2,b2;

scanf("%lld",&n);
if(n%2==0){
     printf("1");
}else{
    printf("0");
}
return 0;
}

#include <stdio.h>
#include <string.h>
int main()
{
      int l;
      //char s[25];
      scanf("%d",&l);
      //l=strlen(s);
      printf("1");
      return 0;
}

#include <stdio.h>
int main(){
	int n;
	scanf("%d",&n);
	if (n>2){
		printf("%d",n-(n-1));
	}
	else if(n=2){
		printf("%d",1);
	}
	else if (n=1){
		printf("%d",1);
	}
	return 0;
}

#include <stdio.h>
int main()
{
int n;
scanf("%d",&n);
if(n!=2)
printf("2");
else
printf("0");
return 0;
}

#include <stdio.h>
int main()
{
int n;
scanf("%d",&n);
if(n!=2)
printf("1");
else
printf("0");
return 0;
}

#include <stdio.h>

int main(void)
{
 int v;
 scanf("%d", &v);

 printf("1");

return 0;
}

#include <stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
long long cmpfunc (const void * a, const void * b) {
   return ( *(long long*)a - *(long long*)b );
}

int main(void){

long long int test,i,j,n,count,flag=0,o1=0,o2=0,b1,x,m,l,max,sum2,min,f,c,r,o,sum1,sum=0,y,a,b,count1=0,a2,b2;

scanf("%lld",&n);

     printf("1");

return 0;
}

#include<stdio.h>
int main(){
int a;
scanf("%d",&a);
printf("1\n");
return 0 ;
}

#include <stdio.h>
#include<string.h>

int main()
{
    char n[100];

    scanf("%s",n);
   if(strlen(n)%2==1)
   {
       printf("1");
   }else{
       printf("2");
   }

    return 0;
}

#include <stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
long long cmpfunc (const void * a, const void * b) {
   return ( *(long long*)a - *(long long*)b );
}

int main(void){

long long int test,i,j,n,count,flag=0,o1=0,o2=0,b1,x,m,l,max,x1,y1,k,sum2,min,f,r,o,sum1,sum=0,y,count1, a[26]={0};
char a1[100000];
scanf("%lld",&n);

    printf("1");

return 0;
}

#include<stdio.h>
int main()
{
int n;
scanf("%d",&n);
	if(n==2)
	{
		printf("0");
	}
	else
	{
		printf("1");
	}
	return 0;
}

#include<stdio.h>

int main()
{
    int n;
    scanf("%d",&n);
    printf("%d\n",n-(n-1));
    return 0;
}

#include <stdio.h>

 int main (){
	int n;
	int x;
	scanf("%d",&n);
	for (x=1;x<n;x++){
		if (n%x!=0){
			n=n-x;
		}

	}
	printf("%d\n",n);
	return 0;
}

#include<stdio.h>

int main()
{
    int n,x=1;

    scanf("%d",&n);

    while(1)

    {

        if(n==1 || n==2)
        {
            printf("1");
            return 0;
        }

    if(n%x==0)
    {
        x++;
    }
    else
    {
        n=n-x;
        x++;
        if(n<x)
        {
            printf("%d",n);
            return 0;
        }
    }

    }

    return 0;
}

#include<stdio.h>
int main()
{
    int a,b,s,i;
    scanf("%d",&a);

    printf("1\n");

    return 0;
}

#include<stdio.h>
int main()
{
    int a;
    scanf("%d",&a);
    printf("1");
}

#include<stdio.h>
int main()
{
    int n,x;
    scanf("%d",&n);

        printf("%d\n",n);

    return 0;
}

#include<stdio.h>
int main()
{
    int n,x,i;
    scanf("%d",&n);
    while(n>2){
        for(i=2;i<n;i++){
            if(n%i!=0)n=n-i;
            if(n==5)n=1;
        }
    }
    printf("%d",n);
}

#include<stdio.h>
main()
{
	int n;
	scanf("%d",&n);
	if(n>2)
	{
	if(n%2==0)
	printf("1\n");
	if(n%2!=0)
	printf("2\n");
	}
	else
	{
		printf("1\n");
	}
	return 0;
}

#include<stdio.h>
int main(){
	int n;
	scanf("%d", &n);
	printf("1");
	return 0;
}

#include <stdio.h>
int main() {
	int n;
	scanf ("%d",&n);
if(n>2){
	printf("%d",n-(n-1));
}
if(n==2) {
	printf("%d",2);
}
	return 0;

}

#include<stdio.h>
main()
{
	int n,i=2;
	scanf("%d",&n);
	if(n>3)
	{
	while(1)
	{
	if(n%i==0){i++;}
	if(n%i!=0)
	{
		n=n-i;
		i++;
		if(i>=n)
		{
			printf("%d\n",n);
			return 0;
		}
	}
	}
	}
	else
	{printf("1\n");}
	return 0;
}

#include<stdio.h>
int main(){
   int t=0,i=1,n=0;
   scanf("%d",&n);
   while(n>1){
      i=1;
      while(i<=n){
      if(n%i!=0)break;
      i++;
      }
      n=n-i;
   }
   if(n<0)
   printf("%d",n+i);
   else    printf("%d",n+i);
}

#include<stdio.h>
int main()
{
    long long int v;
    scanf("%d",&v);
    if(v==1)
        printf("1");
    else if(v==2)
        printf("2");
    else
        printf("1");
    return 0;
}

#include <stdio.h>
int main()
{
int n;
scanf("%d",&n);
if(n!=2)
printf("2");
else
printf("0");
return 0;
}

#include<stdio.h>
int main(){
int m;
while(scanf("%d",&m)==1){
printf("1");}
return 0;}

#include<stdio.h>

int main(void)
{

    int x;
    scanf("%d",&x);

    printf("1");

    return 0;
}

#include<stdio.h>
int main(){
long int n;
scanf("%ld",&n);
printf("11");
return 0;
}

#include<stdio.h>
int main()
{
int n;
scanf("%d",&n);
	if(n==2)
	{
		printf("0");
	}
	else
	{
		printf("1");
	}
}

#include<stdio.h>
int main()
{
    long long int n;
    scanf("%lld",&n);
    if(n>2)
      printf("1");
    else
        printf("2");
}

#include<stdio.h>
int main()
{
 long long int n,d;
 scanf("%lld",&n);
 int i;
 for(i=2;i<n;i++)
 {
     if(n%i!=0 && i<n)
     {
         d=n-i;
         n=d;
     }
 }
 printf("%lld",n);
 return 0;
}

#include<stdio.h>
int main()
{
    int n;
    scanf("%d",&n);
    printf("1");
    return 0;
}