CHEFCODE - Editorial

Will you please explain your approach? @hafiz_00

Isn’t this brute-force for languages supporting big-int ?
By the way got wa on my answer here. Any help on the same would be appriciated. :smiley:

pr[j]/pr[i-1] is an issue here.
Try print(1/2) and see the output.

Maybe yes if you are talking about soln other than meet-in-the-middle.
You can do it in c++ as well. CC’s c++ supports __int128. ;p

Edit - Your soln is also wrong. You read question wrong.

1 Like

Wow. Thanks, I didn’t know that.

Yeah, I see the difference between subsequence, and subsegment.
Thanks for the answer.

August ke liye badi taiyaari chal rahi hai I can see that :stuck_out_tongue:

1 Like

Jo hona tha, vo vaccation me ho gya, ab college waale free time de toh hi kch ho paaega :sweat_smile::sweat_smile::sweat_smile:

What is GPD?