#include using namespace std; int main() { unsigned long long n; cin>>n; long long x = sqrt(1 + 8 * n); if (x * x != 1 + 8 * n) { cout<<"NO"<