using System; using System.Collections.Generic; using System.Collections; using System.Collections.Specialized; using System.Linq; using System.Text; using System.IO; using System.Reflection; using static System.Math; using System.Numerics; using System.Threading; using System.Runtime.CompilerServices; using System.Diagnostics; static class Program{ const int mod=(int)1e9+7; static void Main(){ Sc sc=new Sc(); var n=sc.I; var ans=n==3?"YES":"NO"; Pn(n,(e)=>{ if(e%2==1&&e!=1&&e!=n&&n/e-e/2>=0){ ans="YES"; } }); for(int i = 4;i<1000000&&n-(i>>1)>0;i+=2) { int p=n-(i>>1); if(p%i==0&&p/i-i/2+1>=0){ ans="YES"; break; } } Console.WriteLine("{0}",ans); } static void Pn(int n,Action f){ var q=Sqrt(n); for(int i = 1;i(int n,Func f){var a=new T[n];for(int i=0;i(int n,Func f){var a=new T[n];for(int i=0;i(int n,Func f){var a=new T[n];for(int i=0;i(int n,Func f){var a=new T[n];for(int i=0;i