# Need the C++ code of a problem in April Long Challenge (2021)

Could some one provide me the solution of the problem " World Record" for the April Long Challenge (2021) of Division 3.
The code created by me has some issues I don’t know what , check it out if it worth to watch
#include
using namespace std;

float one(float *deci)
{
float value = (int)(*deci * 10);
return value / 10;
}
float two(float *mal)
{
float value = (int)(*mal * 100);
return value / 100;
}

int main()
{
int t;
cin>>t;
while(t–)
{
float k1,k2,k3,v,t,j;
cin>>k1>>k2>>k3>>v;
one(&k1);
one(&k2);
one(&k3);
two(&v);
if(0<(k1,k2)<2)
{
if(0<k3<=1)
{
if(9<v<11)
{
j = vk1k2*k3;
}
}
}
t = 100/j;

``````    if(t<9.58)
cout<<"Yes";
else
cout<<"No";
}

return 0;
``````

}

1 Like

dude u can check editorials for better understanding

Bro I didn’t found anything useful yet.

https://www.codechef.com/viewsolution/44396870
You can check my solution

Bro your code too was submitted but could not satisfy the subtask.
Try to put this input set to your code (test case = 1 , k1 = 1.03 , k2 = 1.04 , k3 = 1.05, v = 10.21) it should print “No” but it will not .
The point is I don’t have any problem in submitting my code, its just the fact I wanna pass all the constraints given in the problem.
If you observe my code I’ve put nested if be the calculation of “t” just to pass all the constraints , I’m still wondering what went wrong.

Bro it should print “YES” because the multiplication if k1 * k2 * k3 * v = 11.4837996 and when we divide it by 100 :- 100/11.48 = 8.71 sec. This means he can beat the world record. So the answer should be YES

HImanshu bhai , I don’t know if I’m interpreting it right , but the problem constraints clearly says k1,k2,k3 contains one digit after decimal, that mean no matter if I put 1.0 or 1.03 or 1.054 , it should consider it as 1.0 only. (Restricting the decimal , PS that’s what I’ve done in my code before the main function)