(Subscribe for more such videos) Code : #include using namespace std; #define ll long long int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
You always covers the concept in depth which always gives me a new idea every time to approach for any new question. Thank u so much sir pls keep continuing this.
I solved this in 2min thinking that printing the max value n times would suffice, but then i came back after solving c and saw the wrong answer. (How can i even forgot that sum is r😅). Thanks for the explaination.
(Subscribe for more such videos)
Code :
#include
using namespace std;
#define ll long long
int main()
{
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
ll t, n, s, r, i, j, val;
cin>>t;
for(;t--;)
{
cin>>n>>s>>r;
val=s-r;
cout
thanks sir make more and more videos
Thank you sir...
thanks
You always covers the concept in depth which always gives me a new idea every time to approach for any new question. Thank u so much sir pls keep continuing this.
sir there is nested loop in this then why complexity was not O(tn^2)?
I solved this in 2min thinking that printing the max value n times would suffice,
but then i came back after solving c and saw the wrong answer.
(How can i even forgot that sum is r😅).
Thanks for the explaination.
need solution d, e
thank you sir