long a;j=1e7,t;main(i){for(scanf("%ld",&a);i++j?a:i--,t^=1););a=!puts(a>1?"YES":"NO");}