r/programming • • Aug 10 '12

Write any javascript code with just these characters: ()[]{}+!

http://patriciopalladino.com/blog/2012/08/09/non-alphanumeric-javascript.html
1.3k Upvotes

288 comments sorted by

View all comments

9

u/SgtSausage Aug 10 '12

Write anything in any language with just these characters: 0 1

2

u/chromaticburst Aug 10 '12

Write anything in any language with just one instruction.

-4

u/SgtSausage Aug 10 '12

only works if your addressable memory (and the memory location operand to the instruction) are infinite, but ... Yeah. Good one.

2

u/dont_press_ctrl-W Aug 11 '12

Infinite memory is a requirement for everything to be Turing complete. That's not a shortcoming of the program, that's a shortcoming of reality.

And yet you can make things work if you settle down to use a finite but sufficiently large memory. Including a OISC.

-4

u/SgtSausage Aug 11 '12

We're not talking about Turing Completeness here. At all.

At. All.

Go back and re-read, then re-examine your assumptions about the discussion.

I know - it's subtle, but if you try hard enough, you'll get it.

0

u/dont_press_ctrl-W Aug 11 '12

I assumed you were referring to the start of the Wikipedia article you were linked to, in which case your comment was inaccurate, but sensical. Now your claim is just straight up wrong, bizarre, irrelevant, and disconnected from the discussion. I'm sorry for assuming the best of you.

With a reasonably large but finite memory, you can theoreticallly achieve most basic algorithms that are in use in everyday computers with a OISC.

→ More replies (2)