### farmaan_khan's blog

By farmaan_khan, history, 4 months ago,

183368493 please see my solution and tell me why i get run time error please dont ignore i am dugging this more than hours PLEASE!!!

• 0

By farmaan_khan, history, 4 months ago,

https://codeforces.com/contest/1225/my 182321559 any body tell me why there is overflow

• -4

By farmaan_khan, history, 4 months ago,

https://codeforces.com/contest/1539/problem/A i am not able to solve the problem because of constraints the first solution is this

# define ll long long

using namespace std; void solve(){ ll n,x,t; cin>>n>>x>>t; int v[n]={0}; for(int i=1;i<n;i++) v[i]=v[i-1]+x; // for(auto i:v) cout<<i<<" "; // cout<<endl; int vv[n]={0}; for(int i=0;i<n;i++) vv[i]=v[i]+t; // for(auto i: vv ) cout<<i<<" "; // cout<<endl; ll sum=0; for(int i=0;i<n-1;i++){ ll upper1 = upper_bound(v, v+n, vv[i]) — v; sum+=upper1-i-1; } cout<<sum<<endl;

} int main() { int tc; cin>>tc; while(tc--){ solve(); } } 2.nd solution is this

# define ll long long

using namespace std; void solve(){ ll n,x,t; ll ans=(max(0ll,(n-t)/x)*(t/x))+min((n-1),t/(x-1))*(min(n,(t/x)))/2; cout<<ans<<endl;

} int main() { int tc; cin>>tc; while(tc--){ solve(); } } IN FIRST ONE IT SHOWS RUN TIME ERROR BECOZ OF CONSTRAINT AND IN 2ND IT SHOWS RANDOM NUMBER MAY BE BECAUSE OF 0LL HELP ME PLEASE!!!!1:(

• -23

By farmaan_khan, history, 5 months ago,

plz any body gives me list of some common patterns in question ask in rounds and some technique please dont ignore this persons who give me the list or some ideas has some positive DELTA in their next round ?

• +7

By farmaan_khan, history, 6 months ago,

If in contest i submit my problem 5 times and its is unaccepted submission and after that problem statment chnge due to some error does my previos 5 submission matter or it just discarted.. because it is not my fault.

• -16

By farmaan_khan, history, 8 months ago,

What i do my codeforces telegram link is not working

• 0

By farmaan_khan, history, 8 months ago,

many times i come up with solution some times the solution is brute force and some time it is optimised one. but onces i am done with the problem.(i.e accepted) one question is always strick in my mind that WHY MY SOLUTION IS TRUE.. how do i proof that it is always give me the correct ans....... so that is why i am always in delema that i dont understand the problem and solution well enough SO ANY SUGGESTION..(my english is weak XD sorry!!)

• 0

By farmaan_khan, history, 8 months ago,

2 days back i answered 3 question in div-4 contest but today i recieve a message in my box that says you copy the code of question 3 from some random person but this is not true and the system dequalified me for that round i.e there is no + in my rank what should i do then.. any suggestion

• +2