fork(1) download
  1. #include<bits/stdc++.h>
  2. using namespace std;
  3. int main()
  4. {
  5. int t;
  6. cin>>t;
  7. while(t--)
  8. {
  9. int n;cin>>n;
  10. int count=0;
  11. if(n<2020)
  12. {
  13. cout<<"NO"<<"\n";
  14. break;
  15. }
  16. else
  17. {
  18.  
  19.  
  20. if((n%2020)==0 || (n%2021)==0)
  21. {
  22. count++;
  23. }
  24.  
  25.  
  26. }
  27. if(count%2==0)
  28. {
  29. cout<<"NO"<<"\n";
  30. }
  31. else
  32. {
  33. cout<<"YES"<<"\n";
  34.  
  35. }
  36.  
  37. }
  38. }
Success #stdin #stdout 0s 4836KB
stdin
5
1
20210
20211
8081
8079
stdout
NO