Codeforces and Polygon may be unavailable from May 23, 4:00 (UTC) to May 23, 8:00 (UTC) due to technical maintenance. ×

Getting TLE in Python where same logic get passed in C++

Revision en2, by i_m_Shakil, 2020-04-28 11:24:13

Problem Link: 231C - Прибавляй не прибавляй

These are my two submissions:

Both of these solutions are written using the same logic & run time is O(n log n). Why is Python getting TLE?

N.B: I'm new in python.

Thanks in Advance.

Tags #binary search, #python 3, #tle

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English i_m_Shakil 2020-04-28 11:24:13 222 Tiny change: ':231C]**\n****\nThese ar' -> ':231C]**\n\nThese ar' (published)
en1 English i_m_Shakil 2020-04-28 11:11:27 182 Initial revision (saved to drafts)