sir why my code is wrong answer in test case
Book allocation problem
source.cpp: In function ‘int find(int*, int, int, int)’:
source.cpp:47:1: warning: no return statement in function returning non-void [-Wreturn-type]
47 | }
| ^
You need to make int find() to void find()
sit ushko maine banna diya magar ushka baad bhi nahi test case pass ho raha hai
sir please reply i wanted to know my mistake
looking at it again wait…
Please try making int to long long int
Also is there the condition of taking t ( no. of test cases ) ?? If not comment the cin>>t line
I have tested some of the test cases and It was giving correct output!
If you still face issues refer this code: https://ideone.com/P53XxQ