Submission #1749267
Source Code Expand
#include<iostream> #include<cmath> double X; using namespace std; int main() { cin >> X; cout << long long(ceil((-1 + sqrt(1 + 8 * X)) / 2)) << endl; return 0; }
Submission Info
Submission Time | |
---|---|
Task | C - Go Home |
User | Sen |
Language | C++14 (GCC 5.4.1) |
Score | 0 |
Code Size | 178 Byte |
Status | CE |
Compile Error
./Main.cpp: In function ‘int main()’: ./Main.cpp:10:10: error: expected primary-expression before ‘long’ cout << long long(ceil((-1 + sqrt(1 + 8 * X)) / 2)) << endl; ^