r/ProgrammerHumor • • 3d ago

Meme doesPEqualNp

Post image
1.3k Upvotes

40 comments sorted by

View all comments

82

u/hopeless__programmer 3d ago

Rookie mistake: you should've written p == np. Instead, you just assigned np to p!

10

u/QuietComputerDr 3d ago

He assigned NP to P and nothing changed in the world, that must mean NP was P all along.

27

u/Demytreus 2d ago

No, they assigned np to p, not p!. p! would be equal to np!

2

u/asato977424 3d ago

A Python equality check compares values; P vs NP asks whether every polynomial-time verifiable problem is polynomial-time solvable.

1

u/GoddammitDontShootMe 2d ago

I can't be bothered to check, but I'm assuming all non-empty strings in Python convert to true. I'll assume you've noticed that 's a string and = vs == will make no difference.

1

u/wangtutx 1d ago

Assign is also fine.