[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
Let's have an actual programming puzzle thread. No stabbing

You are currently reading a thread in /g/ - Technology

Thread replies: 4
Thread images: 1
File: Clrs3.jpg (50 KB, 420x475) Image search: [Google]
Clrs3.jpg
50 KB, 420x475
Let's have an actual programming puzzle thread. No stabbing birds allowed.

Write a quine: a program that outputs its own source code. This generally means you must use a print statement.

-No REPL
-No file IO
-No blank/only-whitespace files
-stdout must match exactly the source, including all quotation marks.

I'll post my solution in Python2 in a bit. Here's some code to get started

print 'print'
>>
any takers?

Hint 2:
print 2*'print'


Code to test your solution on Linux
diff <(binary <(binary quine.ext)) quine.ext

should return no output.
>>
>>55642775
Your puzzle sucks and you should feel bad. You should have posted this in /dpt/
>>
>>55643025
donezo friend :)

>>55643067
Thread replies: 4
Thread images: 1

[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
If a post contains illegal content, please click on its [Report] button and follow the instructions.
This is a 4chan archive - all of the content originated from them. If you need information for a Poster - you need to contact them.
This website shows only archived content and is not affiliated with 4chan in any way.
If you like this website please support us by donating with Bitcoin at 1XVgDnu36zCj97gLdeSwHMdiJaBkqhtMK