Are there any real O(n^n) algorithms?

后端 未结 5 719
醉梦人生
醉梦人生 2021-02-01 03:19

Is there any real Algorithm with a time complexity O(n^n), that isn\'t just a gimmick?

I can create such an Algorithm, like computing n^n in O(n^n) / Θ(n^n):

<         


        
5条回答
  •  -上瘾入骨i
    2021-02-01 03:50

    According to Wikipedia, there are some double exponential time problems O(22poly(n)) which is more complex than O(nn), e.g. "Decision procedures for Presburger arithmetic" (O(22cn)) and "Computing a Gröbner basis" (in worst case O(22n/10)

提交回复
热议问题