Beta

Slashdot: News for Nerds

×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

1K JavaScript Madness

CmdrTaco posted more than 3 years ago | from the fits-on-a-postcard dept.

Programming 131

An anonymous reader writes "JS1k has a simple goal: to get programmers producing demos written in JavaScript that are 1k in size or less. That's just 1024 bytes to play with. There's even additional bonus points on offer if a demo's code can fit inside a single tweet. Now that the contest is finished and there is a top-ten, I'm wondering what they can do if given some extra bytes." I like the Tetris clone. The pulsing wires demo is neat too but kinda stuttery on my machine.

cancel ×

131 comments

I'm sure Twitter is delighted (3, Funny)

space_jake (687452) | more than 3 years ago | (#33727260)

About javascript in their tweets...

Re:I'm sure Twitter is delighted (4, Funny)

WrongSizeGlass (838941) | more than 3 years ago | (#33727632)

About javascript in their tweets...

If they aren't just give it some time ... I'm sure it will worm its way into their hearts ;-)

Re:I'm sure Twitter is delighted (1, Funny)

Anonymous Coward | more than 3 years ago | (#33727644)

<script>alert("twitter sucks")</script>

js1337 (3, Funny)

user24 (854467) | more than 3 years ago | (#33727266)

>I'm wondering what they can do if given some extra bytes.

In a few weeks you'll find out at js1337.com ;0)

Re:js1337 (1)

toastar (573882) | more than 3 years ago | (#33727292)

>I'm wondering what they can do if given some extra bytes.

In a few weeks you'll find out at js1337.com ;0)

This sounds epic

Re:js1337 (0)

Anonymous Coward | more than 3 years ago | (#33727648)

Should be good, an extra 313 bytes to play with! (Anyone that entered js1k will know just how big 1k feels after you've been fiddling for a while)

Re:js1337 (0)

Anonymous Coward | more than 3 years ago | (#33728608)

@Anonymous\ Coward - like your 4" cock feels big compared to an asian?

Re:js1337 (1)

MoonBuggy (611105) | more than 3 years ago | (#33727770)

Or maybe just head over to the5k [the5k.org] or 10k Apart [aneventapart.com]

Re:js1337 (0, Offtopic)

terminallyCapricious (1838672) | more than 3 years ago | (#33730318)

;0)

hAhAh FuUuUuCk, YoU sToLe My FuCkIn NoSe BrO!

WhAt GoT yOu EvEn Up ThE gUmPtIoN tO aLl FuCkIn Do ThE sHiT lIkE tHaT?

And BOOM (3, Funny)

Anonymusing (1450747) | more than 3 years ago | (#33727306)

Is there a Javascript app for "This site has been Slashdotted"?

Re:And BOOM (1)

Nesman64 (1093657) | more than 3 years ago | (#33727344)

4 comments and the site is already crawling. Reddit must have hit it first.

Re:And BOOM (1)

AltairDusk (1757788) | more than 3 years ago | (#33727408)

Actually when I first saw this with 0 comments the site loaded instantly, by the time I tried to load one of the Javascript apps Slashdot had hammered it into oblivion.

Re:And BOOM (1)

lowrydr310 (830514) | more than 3 years ago | (#33727836)

Perhaps their server's OS is less than 1K

Still too many bytes (1)

Saishuuheiki (1657565) | more than 3 years ago | (#33727570)

Apparently they should have made their size requirement smaller. 1024 is apparently taking too much time for their site to handle.

It is a bold demonstration as to why we

Re:And BOOM (5, Funny)

WrongSizeGlass (838941) | more than 3 years ago | (#33727720)

I'm not impressed ... maybe I'll try again, but this time I'll turn off NoScript.

Re:And BOOM (4, Informative)

ChrisMounce (1096567) | more than 3 years ago | (#33728444)

Coral Cache links for ya:
  1. Legend Of The Bouncing Beholder [nyud.net] by @marijnjh [twitter.com]
  2. Tiny chess [nyud.net] by Oscar Toledo G. [110mb.com]
  3. Tetris with sound [nyud.net] by @sjoerd_visscher [twitter.com]
  4. WOLF1K and the rainbow characters [nyud.net] by @p01 [twitter.com]
  5. Binary clock [nyud.net] (tweetable) by @alexeym [twitter.com]
  6. Mother fucking lasers [nyud.net] by @evilhackerdude [twitter.com]
  7. Graphical layout engine [nyud.net] by Lars Ronnback [twitter.com]
  8. Crazy multiplayer 2-sided Pong [nyud.net] by @feiss [twitter.com]
  9. Morse code generator [nyud.net] by @chrissmoak [twitter.com]
  10. Pulsing 3d wires [nyud.net] by @unconed [twitter.com]

Re:And BOOM (1)

commodore64_love (1445365) | more than 3 years ago | (#33729316)

If I were entering this competition, I'd just take some old 2K atari or VIC-20 games and modify them. Stuff like Space War, Combat, Breakout, Pitfall

Re:And BOOM (1)

eulernet (1132389) | more than 3 years ago | (#33729486)

It's because their server is written in Javascript.

I'm pretty sure they put pictures bigger than 1K !

the most uberest slashdotting evar (1)

digitalsushi (137809) | more than 3 years ago | (#33727330)

"Hey slashdot kids. It's 4pm east coast. Here's 10 games you can play, hosted on this site here. See you all at the coffee machine in 180 seconds."

Re:the most uberest slashdotting evar (1)

harrkev (623093) | more than 3 years ago | (#33727610)

HUH? I do not see what the big deal is. Each script is only one single friggin kilobyte! Even though each page includes the source and some comments, and the usual HTML wrappers, I cannot imagine each page being more than about 5K to 10K each. Evan an old Pentium should be able to keep up with that kind of load.

Re:the most uberest slashdotting evar (1)

Fry-kun (619632) | more than 3 years ago | (#33727704)

...and if they used Nginx they could easily withstand both slashing and dotting
Too bad they've only got Apache with PHP

Re:the most uberest slashdotting evar (1)

camperslo (704715) | more than 3 years ago | (#33730236)

The size of the payload is not included??

Internet Explorere cannot open... (0, Offtopic)

Caption Wierd (1164059) | more than 3 years ago | (#33727366)

Is the site melting or do I just need Chrome?

Re:Internet Explorere cannot open... (1)

AltairDusk (1757788) | more than 3 years ago | (#33727386)

It has been Slashdotted.

Re:Internet Explorere cannot open... (1)

Shikaku (1129753) | more than 3 years ago | (#33727388)

# Must work on current fx, sa, ch and o. (Let's level the playing field)

It doesn't say it supports IE anyway.

Have a nice day.

Re:Internet Explorere cannot open... (3, Funny)

Yvan256 (722131) | more than 3 years ago | (#33727402)

That's a joke, right? Do you really expect Internet Explorer to run cutting-edge web stuff?

Try Chrome, Safari, Opera or Firefox.

Re:Internet Explorere cannot open... (0)

Anonymous Coward | more than 3 years ago | (#33727582)

You kidding? Firefox is just as buggy and bloaty as IE is anymore. I know that IE is a favorite punching bag around here but let's be honest, Firefox is doing a fantastic job of catching up to them.

Re:Internet Explorere cannot open... (1)

Yvan256 (722131) | more than 3 years ago | (#33727642)

That's why it's the last on my list. Opera has some catching-up to do too, last time I tested a few things, Chrome and Safari ran fine but Opera hadn't implemented them yet, such as HTML5 file uploading (for client-side progress bars).
 

Re:Internet Explorere cannot open... (1)

mcgrew (92797) | more than 3 years ago | (#33728098)

I believe the site is "wicked witch of the west.com" and someone threw a bucket of water at it. Maybe its server is programmed in javascript?

Found a bug in tiny ches... (1)

bi$hop (878253) | more than 3 years ago | (#33727378)

...you can't castle queen side.

Re:Found a bug in tiny ches... (4, Informative)

Anonymous Coward | more than 3 years ago | (#33727486)

"[...]it will validate moves, queen-only promotion, without castling and en passant." http://nanochess.110mb.com/ [110mb.com]

Re:Found a bug in tiny ches... (5, Funny)

Iamthecheese (1264298) | more than 3 years ago | (#33727660)

Today, a day that will live in infamy, I was beaten by a 1000 byte program.

Re:Found a bug in tiny ches... (2, Funny)

Anonymous Coward | more than 3 years ago | (#33728014)

That's nothing. Try this short game written in BASIC.

10 GOTO 40
20 PRINT "YOU WIN"
30 GOTO 50
40 PRINT "YOU LOSE"
50 PRINT "GAME OVER"

Re:Found a bug in tiny ches... (1)

CannonballHead (842625) | more than 3 years ago | (#33728088)

Er, 1000 or 1024?

Re:Found a bug in tiny ches... (3, Informative)

ix42 (222898) | more than 3 years ago | (#33728320)

Today, a day that will live in infamy, I was beaten by a 1000 byte program.

Whippersnapper. I seem to recall being beaten more than two decades ago by a 1k chess program on a Timex/Sinclair 1000 (aka ZX81).

Possibly even this one:
http://users.ox.ac.uk/~uzdm0006/scans/1kchess/ [ox.ac.uk]

Re:Found a bug in tiny ches... (1)

Timosch (1212482) | more than 3 years ago | (#33728852)

I had a remis :-/

Asteroids (3, Interesting)

Hatta (162192) | more than 3 years ago | (#33727428)

I'm wondering what they can do if given some extra bytes."

If they use bankswitching, maybe they can pull off Asteroids [atariage.com]

Re:Asteroids (1)

mcgrew (92797) | more than 3 years ago | (#33727846)

I wish I was a better JS programmer, I'd have entered the contest (I've only done a little JS programming, and it's been a few years since I have). I made a fully functional battle tanks game back in 1982 that you could play single-player or two players playing against each other at the same time. It was under 4k as that's all the computer had without an expansion pack; I don't remember how big the actual code was, probably less than 1k. However, it was in hand-assembled Z-80 machine code for the Sinclair 1000, which cuts the size down considerably (the code directly accessed the keyboard hardware and screen memory). Any game that you were punching the membrane keyboard around wouldn't work with the extra memory, as it would come loose.

1k is a lot of code for a simple little game. At least it used to be. I feel old now, thanks guys, my day's bad enough as it is.

I wouldn't think Asteroids would be too hard. It's very similar to the tanks game, except the stationary objects are moving and the moving objects are stationary. Inside the program an object is an object (and I don't mean object in the modern sense; I mean virtual physical object).

Re:Asteroids (1)

Hatta (162192) | more than 3 years ago | (#33728178)

I wouldn't think Asteroids would be too hard.

You're right. In Racing the Beam they say that Asteroids on the 2600 could have been done in 4k with some extra time for optimization but Atari decided that time was money and sprung for the extra ROM chips.

I wonder if this kind of thing is easier to do in Javascript. Given the size of the javascript language themselves, they have a lot more to actually work with. But then javascript is a lot more verbose than 6502 machine language.

Re:Asteroids (0)

Anonymous Coward | more than 3 years ago | (#33728288)

1k is a lot of code for a simple little game. At least it used to be. I feel old now, thanks guys, my day's bad enough as it is.

Um.. if you wrote down any hardware level assembler code as textual processor instructions it would exceed the size it actually requires when you turn it into machine opcodes. Comparing HLL source code size to machine code is stupid.

Re:Asteroids (1)

arth1 (260657) | more than 3 years ago | (#33730572)

Um.. if you wrote down any hardware level assembler code as textual processor instructions it would exceed the size it actually requires when you turn it into machine opcodes. Comparing HLL source code size to machine code is stupid.

Assuming that everybody wrote in assembly and used an assembler to convert it to machine code is even more stupid. I clearly remember entering "CD 27 00 ..." (bonus points to those who remember what these three bytes translated to in Zilog Z80 code) when programming.

nice (1)

vacarul (1624873) | more than 3 years ago | (#33727438)

can they produce a 1k jQuery?

Re:nice (1)

Kristopeit, Mike D. (1900570) | more than 3 years ago | (#33727558)

no. and even if it were possible, generally the use of jquery is usually done through a cached resource... 1k vs 4k vs 24k is pretty much exactly the same, except for the the initial loading, and only then on slow dialup connections.

as jquery removes support for older browsers, the size will reduce.

Re:nice (1)

vacarul (1624873) | more than 3 years ago | (#33727832)

initial loading it's still important (for me at least). Big homepages remind me of MS Live search engine that had a 500k homepage and that search engine lost the race.

Also, not only dialup is slow. Broadband but shitty internet connection is also slow. Free internet is slow (airports etc). In developing countries it is slow. In Africa it is slow.

I was thinking that maybe it would be possible a lite version.

Good to know that they will remove support for old browsers.

Re:nice (1)

CastrTroy (595695) | more than 3 years ago | (#33727894)

There really should be a way to generate a custom jQuery library. Basically input all the functions your run, or maybe check off a list of things you need, and a custom built version will all dependencies is created. Would save a lot of code especially for many of the cases where jQuery is just used to get cross browser AJAX requests working, with majority of the code going unused.

Re:nice (2, Interesting)

Kristopeit, Mike Da. (1905342) | more than 3 years ago | (#33728034)

generally if you want that level of granularity, you would never use jQuery, and instead build something custom.

for my work i built a JSON-RPC development environment which automated the client and server creation like you're asking for... it's not that complicated.

jQuery is for prototyping... if you're depending on it for production systems, you're lazy.

Re:nice (2, Insightful)

TheNinjaroach (878876) | more than 3 years ago | (#33728250)

jQuery is for prototyping... if you're depending on it for production systems, you're lazy.

Or saving your employer time and money. Sometimes being "lazy" isn't so bad.

Re:nice (1)

Kristopeit, Mike Da. (1905342) | more than 3 years ago | (#33728448)

sometimes delivering the highest quality product is best... all of the time, in fact.

Re:nice (2, Insightful)

Anonymous Coward | more than 3 years ago | (#33730302)

No. That's an absurd statement. Perhaps you meant to say: " All things being equal [wikipedia.org] , delivering the highest quality product is best, all of the time." which most people would agree is correct.

Fast, cheap, good. Pick two. [wikipedia.org] If you're able to duplicate all the functionality you need, better than jQuery, in less time than it would have taken to use jQuery then good for you! For those of us bound by reality, perfection comes at a cost. What if, in the time it takes you to ship the "Highest Quality" product, your competitor pushes their "Good Enough" product (or prototype) out the door, corners the market and steals your lunch?

Depending on your application, you could still have the last laugh but recall twitter and the downtime it suffered in the beginning, or the recent (and not so recent) security vulnerabilities. If you wrote a complete, bug-free, "Highest Quality" version of Twitter, without any security vulnerabilities or downtime, and you released it tomorrow, how many people would jump-ship and start using your version?

Re:nice (0, Flamebait)

Kristopeit, Mike Da. (1905342) | more than 3 years ago | (#33730462)

some people like to justify their delivering of shit.

others, like me, take pride in the product they deliver.

you know who made up the "fast/cheap/good, pick two" rule? lazy, bad, slow, overpriced developers with no talent.

i guarantee i can deliver the same product done correctly as a developer only offering 66% of my potential for the same price... that is if i wasn't employed full time by a company that understands the difference between a job done right and a prototype running on production servers.

... and now, i'm sure, you'll tell me about your hosting company that runs 1000 web servers on one machine all in their own virtual environment... IT'S SO CHEAP AND EASY!

go attempt to justify subpar work to someone who doesn't understand that you're an idiot.

Closure (3, Informative)

pavon (30274) | more than 3 years ago | (#33728418)

You want a static code analysis tool that can perform dead code elimination. It looks like Google's Closure Complier [google.com] will do that for JavaScript code.

Re:Closure (1)

vacarul (1624873) | more than 3 years ago | (#33729188)

thanks!

Re:nice (1)

Kristopeit, Mike Da. (1905342) | more than 3 years ago | (#33727952)

most of the delay in shitty internet connections is latency for new connections... if a website was including jquery from a 3rd party server, then a new connection would be required... if the code was delivered inline, there would be no noticeable delay.

i'm not sure they WILL remove support for old browsers, but as they did the size would reduce.

coral-cached copies of each one (5, Informative)

radarsat1 (786772) | more than 3 years ago | (#33727528)

Re:coral-cached copies of each one (1)

blair1q (305137) | more than 3 years ago | (#33727654)

Nope. Slashdotted those, too. Someone needs to put these on some embiggener iron.

Re:coral-cached copies of each one (1)

Arrepiadd (688829) | more than 3 years ago | (#33727752)

Not that it matters at all, but the "Tiny Chess" cannot castle with the king rook (at least).

Other than that, it looks pretty nice!

Re:coral-cached copies of each one (1)

tomhudson (43916) | more than 3 years ago | (#33728212)

I beat it first try, and it just sits there. Apparently, 1023 bytes isn't big enough to say "You win". (And it can't be that good - I haven't played chess in decades).

Re:coral-cached copies of each one (0)

Anonymous Coward | more than 3 years ago | (#33728738)

Not that it matters at all, but if you bothered to read the description of the game: "Play chess against computer with queen-only promotion and without castling or en passant"

Genetic approach (2, Interesting)

Iamthecheese (1264298) | more than 3 years ago | (#33727536)

Would it be feasible to take a current simple game like Pacman, write a driver to check it for proper functionality on an x86 CPU, spawn thousands of them in minor variations, and use a genetic algorithm to keep the smallest?

Re:Genetic approach (1)

blair1q (305137) | more than 3 years ago | (#33727624)

Sure. But how do you define "minor variations" such that more than a handful out of "thousands" function at all?

Re:Genetic approach (1)

Iamthecheese (1264298) | more than 3 years ago | (#33727746)

You don't: a handful must be enough. Then you spawn thousands of children from that handful.

Re:Genetic approach (1, Offtopic)

blair1q (305137) | more than 3 years ago | (#33728126)

I think if you can devise a few variation methods that work at all, you could make a good guess at which lead to the smallest code.

What you need are thousands of methods of varying the code, and millions of iterations looking for working results, and then a cost function (in this case merely size) to choose the optimal result.

Re:Genetic approach (4, Insightful)

TelavianX (1888030) | more than 3 years ago | (#33727740)

This is possible, but how many valid javascript programs are 1024 characters or less? A very large amount!

Checking each if it followed the predefined rules would be time consuming. For instance, in Pacman, you might have to have the computer play a full game to check if the rules are met.

Almost all the programs would be utter nonsense.

Re:Genetic approach (2, Informative)

Anonymous Coward | more than 3 years ago | (#33728626)

Sorry to spoil your party, but you will be dealing with issues in automatic software verification which themselves are infeasible.
This is one problem you can't just throw a bunch of computing power (yet) and it will magically find it a small solution in a reasonable amount of time.

Just fyi, assuming each character has 256 different possibilities in a 1000 byte program in js, there are 256^1000 possibilities, or 2^8000 possible programs to choose from.
To put that into perspective, current estimates on the number of atoms in the observable units are around 10^80 which is ... 2^8000

.nyud.net FFS! (0)

Anonymous Coward | more than 3 years ago | (#33727542)

This is obviously something a large percentage of /.'ers would be checking out, so can we please play it safe and add .nyud.net as a precaution next time?

Reminds me of thek5.org (2, Interesting)

MayorOfTuesday (1911042) | more than 3 years ago | (#33727694)

http://www.the5k.org/ [the5k.org] Does anyone remember this site? It was a contest back in 2000-2002 to create the coolest website with only 5KB. Looks like it had a spiritual successor too: http://10k.aneventapart.com/ [aneventapart.com]

Re:Reminds me of thek5.org (1)

pjt33 (739471) | more than 3 years ago | (#33727940)

I remember that, and I still have the Mandlebrot applet I wrote for it. I've also had good fun with the Java 4k [java4k.com] contest.

Playing some chess... (1, Funny)

Anonymous Coward | more than 3 years ago | (#33727778)

Chess in 1024 bytes and I can't win it. What a shame.

Nostalgic Terminology (2, Interesting)

psbrogna (611644) | more than 3 years ago | (#33727928)

Interesting idea. Thirty years ago many people were introduced to programming by printed (ink on mashed up trees) anthologies of programs that were generally around a page long (8.5 x 11). Don't know how pervasive the term was, but in my personal circles these programs were called "K-Byters" because they were ~1 K long (or less).

Re:Nostalgic Terminology (2, Informative)

mcgrew (92797) | more than 3 years ago | (#33728190)

I remember them, there were lots of 'em. All computer magazines back then had programs you could type in. IIRC most of them were BASIC, although a few were assembly. Heck, the original Wolfenstein came on a 540k floppy and shareware DOOM was two of them IIRC.

Re:Nostalgic Terminology (1)

pclminion (145572) | more than 3 years ago | (#33728378)

COMPUTE!'s Gazette including listings each month. If I remember, maybe a third of the magazine was devoted to pages upon pages of hex listings. You'd use their machine language entry program "MLX" (BASIC code for which was included verbatim in every single issue -- you'd have to type THAT in first) and sit there for hours typing in the code. It had a simple checksum scheme, so each line was 9 bytes with the last byte being a checksum. If you made a mistake, you found out at the end of the line when the thing goes BEEEEP at you.

My wife has been trying for years to throw away all my old mags. Over my dead freaking body will that happen.

Grrr (1)

Andy Smith (55346) | more than 3 years ago | (#33727982)

Got beaten by the feckin' 1K chess game in about a dozen moves. Feck!

Re:Grrr (1)

UninformedCoward (1738488) | more than 3 years ago | (#33728248)

Don't feel bad, the game doesn't even let you castle...

wtf (1, Insightful)

Anonymous Coward | more than 3 years ago | (#33727992)

>>Now that the contest is finished and there is a top-...

WTF tell me I can win shit then say it's over >:/

What to do with extra bytes (1)

saurongt (1639029) | more than 3 years ago | (#33728044)

I'm wondering what they can do if given some extra bytes

Get them all to work in Internet Explorer. Most demos give errors in IE8x64.

Re:What to do with extra bytes (1)

clone53421 (1310749) | more than 3 years ago | (#33728128)

window.onerror=function(){this.onerror=void(alert('Get a better browser!'))}

Done.

Re:What to do with extra bytes (1, Flamebait)

Unending (1164935) | more than 3 years ago | (#33728224)

Part of the competition was to use Canvas tags in interesting ways, and considering IE9 doesn't even support Canvas I think you're out of luck unless you get a standards compliant browser.

Re:What to do with extra bytes (0)

Anonymous Coward | more than 3 years ago | (#33729414)

IE9 does support canvas. Better check your facts before looking like an idiot.

1024 bytes (0)

Anonymous Coward | more than 3 years ago | (#33728232)

1024 bytes of JavaScript is about 1024 bytes too many.

Moore's law in reverse (0)

Anonymous Coward | more than 3 years ago | (#33728234)

I bet any of these demos could be implemented in Commodore 64 assembly code in less than 1K and still be faster than javascript on today's computers...

Readability... (2, Interesting)

deepu_s (530426) | more than 3 years ago | (#33728246)

It'd be truly impressive if it were *human-readable* source code that fit under 1k.

Re:Readability... (1)

theaceoffire (1053556) | more than 3 years ago | (#33729198)

It is, for certain values of "Human".

Re:Readability... (1)

Symbha (679466) | more than 3 years ago | (#33730526)

That is called magic...

GWT? (0)

Anonymous Coward | more than 3 years ago | (#33728296)

I wonder what java code could be ported with the google web toolkit and remain under the 1K limit.

Chess (3, Interesting)

Dthief (1700318) | more than 3 years ago | (#33728392)

impressed that they fit in a reasonable A.I. into the thing!

Re:Chess (0)

Anonymous Coward | more than 3 years ago | (#33730554)

What? That thing was like -10000 ELO

Tweets (1)

Shadyman (939863) | more than 3 years ago | (#33728530)

"There's even additional bonus points on offer if a demo's code can fit inside a single tweet."

So that kid that made the self-posting Twitter worm the other day wins by default?

1K programs bring back the old days. (1)

Nexusone1984 (1813608) | more than 3 years ago | (#33728536)

My first computer was Tandy 16K color computer, one of the contest in the old Rainbow Magazine was how much you could put in one line of basic code. Still great to see people be creative within a limited space of memory.

One line: (0)

Anonymous Coward | more than 3 years ago | (#33728634)

<script type="text/javascript" src="http://bit.ly/XXXXXX"></script> where http://biy.ly/XXXXXX [biy.ly] redirects to some file with a minimum size of 1 MB.

What about Perl? (2, Interesting)

slapout (93640) | more than 3 years ago | (#33728678)

It just hit me--think of all the stuff you could do in a Perl program that would fit into one tweet?

Re:What about Perl? (1)

SQLGuru (980662) | more than 3 years ago | (#33729032)

Think of all of the things you COULDN'T do in Lisp if you could only use 1k parens...... :D

Re:What about Perl? (0)

Anonymous Coward | more than 3 years ago | (#33729840)

and how would you tell the difference between that code and some guy tweeting after a few beers?

Re:What about Perl? (1)

slapout (93640) | more than 3 years ago | (#33729922)

That's a good point.

Note to self: When hiring Perl programmers, look for heavy drinkers.

Kilobytes, as God (Knuth) intended (2, Funny)

Just Some Guy (3352) | more than 3 years ago | (#33728838)

I can't believe this story's been up for nearly two hours and no one's rushed in to explain that these are one kibibyte demos, thus depriving us of our right to make fun of them and their dumb-sounding pet units.

Re:Kilobytes, as God (Knuth) intended (1)

springbox (853816) | more than 3 years ago | (#33728980)

No need to change; context sensitive units were a great idea!

Re:Kilobytes, as God (Knuth) intended (0)

Anonymous Coward | more than 3 years ago | (#33729390)

context sensitive units were a great idea!

It's not like context-sensitive units are something new. Energy and torque are both measured in newton-meters, yet they have nothing to do with each other. In contrast, the difference between a kilobyte and a "kibibyte" is extremely minor.

k is precisely 1000, K is 1024 (0)

Anonymous Coward | more than 3 years ago | (#33729696)

Dummies never learn.

k = kilo = 1000
K = K = 1024

CS 1001

Really? Only 1k? (0, Redundant)

tyrione (134248) | more than 3 years ago | (#33730126)

It must be nice to not include the entire infrastructure of code that is actually doing the heavy lifting as this fantasy that in only 1K you too can do x,y and z.

Re:Really? Only 1k? (0)

Anonymous Coward | more than 3 years ago | (#33730376)

You could google "Puls by Rrrola" for 256b of "pure DOS code".

Javascript demos at Pouet.net (0)

Anonymous Coward | more than 3 years ago | (#33730338)

Demoscene site Pouet.net search finds a few dozens of javascript demos.

http://pouet.net/prodlist.php?platform[]=JavaScript

Load More Comments
Slashdot Account

Need an Account?

Forgot your password?

Don't worry, we never post anything without your permission.

Submission Text Formatting Tips

We support a small subset of HTML, namely these tags:

  • b
  • i
  • p
  • br
  • a
  • ol
  • ul
  • li
  • dl
  • dt
  • dd
  • em
  • strong
  • tt
  • blockquote
  • div
  • quote
  • ecode

"ecode" can be used for code snippets, for example:

<ecode>    while(1) { do_something(); } </ecode>
Create a Slashdot Account

Loading...