An ooc quine
👋 This page was last updated ~12 years ago. Just so you know.
While preparing my next post about ooc documentation yet again, I stumbled upon an old ooc quine of mine. Here it is in integrality for your pleasure:
q := 34 as Char l := [ "q := 34 as Char" "l := [" "]" "for (i in 0..2) {" " l[i] println()" "}" "for (i in 0..12) {" " q print(); l[i] print(); q println()" "}" "for (i in 2..12) {" " l[i] println()" "}" ] for (i in 0..2) { l[i] println() } for (i in 0..12) { q print(); l[i] print(); q println() } for (i in 2..12) { l[i] println() }
It is very much inspired from the Wikipedia examples for a quine.
Can you find a shorter one?
Here's another article just for you:
I write a ton of articles about rust. And in those articles, the main focus is about writing Rust code that compiles. Once it compiles, well, we're basically in the clear! Especially if it compiles to a single executable, that's made up entirely of Rust code.
That works great for short tutorials, or one-off explorations.
Unfortunately, "in the real world", our code often has to share the stage with other code. And Rust is great at that. Compiling Go code to a static library, for example, is relatively finnicky. It insists on being built with GCC (and no other compiler), and linked with GNU ld ().
not