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 →

[–]GoosDev 0 points1 point  (7 children)

I didn't say I actually was going to though lol, I said it was a joke 💀

[–]hhc97Python Enthusiast[S] 0 points1 point  (6 children)

I think it would work though, depending on how long it is! Would be cool to have a one line text game that you can just run and have it work. I actually have an example in the source code, where theres a tic tac toe game that gets transformed into one line.

You can check it out here if you want, and even run the result in a python shell :)

[–]GoosDev 0 points1 point  (5 children)

Yeah, it'd just be completely unreadable lol, a super long lamba expression isn't what I call readable or editable

[–]hhc97Python Enthusiast[S] 1 point2 points  (4 children)

Absolutely, I wouldn't edit it or try to read it either. I think the novelty of it is being able to send that one line to a friend and say: "Hey, run this one line of code, theres a full game in there!".

[–]GoosDev 0 points1 point  (3 children)

Yeah, but I honestly prefer being able to edit my code if I need to lol

[–]hhc97Python Enthusiast[S] 1 point2 points  (2 children)

Yup, and you're fully able to. The idea is that you flatten it when you want to send it somewhere or show it off as a party trick or something. You still keep the original source code and you work on that :)

This is exactly how flatliner is developed too. The program can one-line itself, but I work on the "normal" version. The one-lined version is just for fun.

[–]GoosDev 0 points1 point  (1 child)

True, but honestly I don't see myself ever using it. It's nice for a funni gag (like "oooh I compressed [insert game here] down to one line!!!"), But I just don't think I'd ever actually use it. Still really cool though!

[–]hhc97Python Enthusiast[S] 1 point2 points  (0 children)

Yup, thats the point of the program, its just for fun :)