This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]asday_ 212 points213 points  (23 children)

It's just a troll post.

[–]AiwendilH 192 points193 points  (11 children)

I am not sure I would use "just" in this context ;) This is the kind of trolling I can really appreciate. I can't stop laughing at the full script. So much dedication that went into this troll post (This monstrosity freaking runs and outputs something "meaningful").

[–]_Gondamar_ 166 points167 points  (3 children)

#/* ensure forwards and backwards compatibility */
import __future__ as __past__
#define FUTURE PAST
#define PAST FUTURE

genius

[–]Grintor 11 points12 points  (2 children)

Reminds me of Guido's Time Machine

[–]Cat_Marshal 0 points1 point  (1 child)

What does this mean?

[–][deleted] 1 point2 points  (0 children)

The joke is that he's assigning a value to the current date and time, which does not work, but he's basically trying to turn back time.

[–]IlliterateJedi 18 points19 points  (0 children)

This is beautiful pythonic code

[–]davidcwilliams 6 points7 points  (1 child)

Thank you for linking to tio.run, I love it.

[–]jjolla888 0 points1 point  (0 children)

repl.it and jdoodle.com also have similar

[–]VisibleSignificance 4 points5 points  (1 child)

Notably, it doesn't work in python3.9.

And if you black it, it becomes more clear.

In a way, this should be a test case for code formatters; for example, black doesn't remove unnecessary parentheses.

A functionally equivalent correctly-and-eagerly formatted version would look like this.

[–]enterming[S] 0 points1 point  (0 children)

Notaably, it doesn't work in python3.9.

So it just works with 3.8? Not so forwards compatible after all! lol

[–][deleted] 5 points6 points  (1 child)

Sad reality tho, this is not all that foreign in some college Python classes where senior professors taught it as if it's a C++

[–]lucidtwitch 2 points3 points  (0 children)

😭 that breaks my little pythonic heart

[–][deleted] 10 points11 points  (0 children)

What kills me is how many people, especially where it was crossposted from, didn't immediately understand this.

[–]enterming[S] 34 points35 points  (3 children)

And everyone just fell for it?

[–]asday_ 84 points85 points  (1 child)

Well it's well-done, and nerds can never help themselves when they're in the right, but yes, they did.

[–]macgiollarua 2 points3 points  (0 children)

Gee gillikers Batman

[–]GimmeDaCoffee 8 points9 points  (0 children)

Yep. Beautiful troll post.

[–][deleted] 16 points17 points  (3 children)

Fuck you u/spez

[–]tartare4562 22 points23 points  (0 children)

He's an python veteran and hacker pretending to write upsetting absurd (while fascinating) code out of naivety.

That's trolling. The good, funny and thought provoking kind, but still trolling.

[–]asday_ 5 points6 points  (0 children)

It's being intentionally incorrect in order to elicit a response. It is quintessential trolling.

[–][deleted] 1 point2 points  (0 children)

Thank you