ishan_luhani's blog

By ishan_luhani, history, 16 months ago, In English

Hello everyone, I am trying to solve this problem: https://mirror.codeforces.com/contest/1861/problem/B

My submission: https://mirror.codeforces.com/contest/1861/submission/221639641

My Python code is running correctly in my ide, but i am getting runtime error in the sample testcase in codeforces!!

Am i missing anything??

  • Vote: I like it
  • 0
  • Vote: I do not like it

| Write comment?
»
16 months ago, # |
  Vote: I like it 0 Vote: I do not like it

"import numpy". You can't use it on codeforces(because there are a lot of math functions in it)

  • »
    »
    16 months ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Thanks. any other alternative??

    • »
      »
      »
      16 months ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      You can implement yours own "numpy" with only functions you need :) I am pretty sure the task can be easily solved without numpy.