QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#383478 | #6749. Target | Teiosama# | Compile Error | / | / | C++17 | 350b | 2024-04-09 14:43:27 | 2024-04-09 14:43:28 |
Judging History
answer
#include<bit/stdc++.h>
using namespace std;
int main()
{
double a,b;
cin>>a>>b;
int ans[60]={0};
int cnt = 0;
while(fabs(a-b)>0.0001)
{
if(a>b)
{
a*=0.5;
ans[cnt++] = 1;
}
else
{
a = a*0.5+0.5;
ans[cnt++] = 2;
}
}
for(int i = 0;i<cnt;i++)
{
cout<<ans[i];
}
cout<<endl;
return 0;
}
Details
answer.code:1:9: fatal error: bit/stdc++.h: No such file or directory 1 | #include<bit/stdc++.h> | ^~~~~~~~~~~~~~ compilation terminated.