achieving linear runtime complexity from a quadratic runtime complexity

前端 未结 0 1590
北荒
北荒 2021-01-19 02:09

Hi i am trying to rewrite this code so, that the runtime is of O(n) instead of O(n^2).

function isWalk(A,L):
    for i in range(0,len(L)-1):
        for j in          


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题