The Most Elegant Sequence

  • + 1 comment

    According to the editorial, the intended solution has time complexity of O((d^2 + n^2) * (2^n)), which means it is of the order 10^8. Does this always fit in the time limit?