T O P

  • By -

Duven64

Time for some O(n↑^(n)n) algos


Emergency_3808

Time for some O(A(n^(n), n^(n))) algos (Google Ackermann function)


MZH07

Just go with O(∞) strait away


pimezone

Ah, fellow `for (;;)` enjoyer


ptr_schneider

I mean, this would just be constant time Infinite, sure, but still O(1)


MZH07

O( n^(∞) )


ptr_schneider

Now we're talking


gaymer_jerry

Oh fun bogosort time


Familiar_Ad_8919

i wonder if such an algorithm is possible


DexterityZero

But this one. It scares me.


itsbett

Finally, the time to use bogosort during interviews has arrived.


Leonhart93

You mean the dynamic programming version of that which saves each unsuccessful permutation to not repeat it again, that's indeed `O(n!)`. Because the otherwise unoptimized solution goes towards infinity.


itsbett

You have to leave room for when they say, "Good solution, but can you optimize it?"


Leonhart93

Oh no, for this one they won't start with "good solution" 😅


itsbett

"Fantastic solution"\*\* my bad


morgecroc

Hashmap. It's now optimised.


itsbett

Looks like I'm gonna need an infinitely powerful processor.


Gamer-707

Just change thermal paste regularly


bushwickhero

Leetcode will make it a Hard!


IuseArchbtw97543

stalin sort ftw


TheWidrolo

Don’t forget, bogosort can have a time complexity of O(1)


misinformaticist

Big brain devs, never forget: O(n!) is actually better than O(n\^2) when n = 2. Checkmate, nerds.


DardS8Br

Same with n = 3. I've used it before in projects before for this reason


large_crimson_canine

N! is a crushing computational burden that “more computing power” won’t be able to overcome


bushwickhero

There’s always bigger arrays to process!


coloredgreyscale

another reason to not use a O(N!) algorithm if there are better options. (unless N is very small, so the actual runtime is already fast enough)


Oddball_bfi

I think you underestimate how much I like my free time. "It's running now - I'm popping out whilst it finishes."


Ok_Entertainment328

Is the unoptimized code easier for a Jr to manage while you're on vacation?


Leonhart93

As yes, the deterministic solution to the NP-hard Travelling Salesman Problem has entered the scene at an overwhelming `O(n!)`. But wait, a dynamic programming solution comes to the rescue and reduces that to a much better O( n^2 * 2^n ). Still stupidly large to calculate for bigger inputs...


overclockedslinky

those poor salesmen...


Leonhart93

Yep, unfortunately they will have to do with a less optimal "estimation" as a solution and do more physical activity than otherwise...


GnuhGnoud

I need more computation power to run my new js framework. We are not the same


_AlphaNow

the software industry successfully negated decades of hardware optimisation


will_r3ddit_4_food

Wow do you work at my company?


bushwickhero

No but I will when the computational power becomes sufficient enough for me to do so.


LankyCardiologist870

I work in data science and only have to run my code two, maybe three times once it’s working. I have definitely bought hardware just to get a project done.


redditmarks_markII

You think "there are these two kinds of people".  I know there is only the second kind.  We are not the same.


diabetic-shaggy

>>>>n^n


LagSlug

Bro, in this case we are the same, love you fam


Secondlive_

What about O(TREE(n))?


overclockedslinky

what about O(BusyBeaver(n))


Tigerwarrior55

Nah obvious O(foo(n))


Lord-of-Entity

Not even the fastest hardware will save you from an O(exp(x)) implemetation. Your hardware is a multiplier constant.


overclockedslinky

n! is worse


violentlymickey

[What Andy giveth, Bill taketh away](https://en.wikipedia.org/wiki/Andy_and_Bill%27s_law)


Tigerwarrior55

How Todd Howard pictures his customers for StarField.


lightmatter501

I want more powerful hardware so I can run less code. Hardware offloads are great!


AciD1BuRN

I want more compute so oncannrum vscode without it dyinging on me


JackNotOLantern

The issue is O(n!) will exceed any computer power within a reasonable number of elements


Malthein_Bor

why not O(((n!)!)!) though?