Register - Login
Views: 99870183
Main - Memberlist - Active users - Calendar - Wiki - IRC Chat - Online users
Ranks - Rules/FAQ - Stats - Latest Posts - Color Chart - Smilies
05-04-22 06:51:38 PM
Jul - Computers and Technology - Let's Programming ~ No bigger than 8KB of code! New poll - New thread - New reply
Next newer thread | Next older thread
Tiden
Disgusting human being, just awful
Level: NaN


Posts: 1845/-6493
EXP: NaN
For next: 0

Since: 07-03-07

Pronouns: they/them

Since last post: 4.1 years
Last activity: 3.6 years

Posted on 01-18-08 03:14:12 AM Link | Quote
So a few of us in #kaibacave had this bright idea (well it was mostly mine, but that's aside the point.) That is, we'll all attempt to write something *functional* in less than 8 kilobytes of code. That gives you 8192 characters of breathing room.

I'm going to go ahead and say there are virtually no restrictions, except that markup languages can't be used (obviously!), and code that runs your program needs to be less than 8K. Compiled languages (like C) that need things like Makefiles can be omitted from this count. External files can be used if your program needs them, as well as external libraries.

Disclaimer: this post was hacked up in a hurry. Corrections will be added accordingly

Now, LET'S PROGRAMMING!

____________________


chungy
Member
Level: 31


Posts: 131/174
EXP: 168466
For next: 16897

Since: 08-04-07


Since last post: 14.1 years
Last activity: 13.9 years

Posted on 01-18-08 03:59:50 AM Link | Quote
So kind of like the IOCCC but no language restriction?

'kay
Deleted User
Collection of nobodies
Posted on 01-18-08 03:59:59 AM Link | Quote
I'll make a quick replacement for PMA because it's running really slow on my website .

____________________


===================
[Posted by NightKev]
Tiden
Disgusting human being, just awful
Level: NaN


Posts: 1847/-6493
EXP: NaN
For next: 0

Since: 07-03-07

Pronouns: they/them

Since last post: 4.1 years
Last activity: 3.6 years

Posted on 01-18-08 04:13:50 AM (last edited by Barney Calhoun at 01-18-08 01:18 AM) Link | Quote
Originally posted by chungy
So kind of like the IOCCC but no language restriction?

'kay

I wasn't going for obfuscation.

Although that does sound like a fun challenge to run around here. 8D

Here's something I hacked up: a simple python script showing the hexadecimal representation of a file (similar to the output of xxd):
import sys as a

e=xrange;filef=open(a.argv[1]).read();mo=16;mrl=(len(filef)/mo)+1;q=len(filef);cdot=lambda x:chr(x) if (x>33 and x<255) else ".";
for i in e(0,(16-(q%160))):filef+=chr(0x00)
for i in e(0,mrl):binout=' '.join([hex(ord(q)) for q in filef[i*mo:(i*mo)+mo]]);print "0x%08x: %s %s"%(i*mo,' '.join(["%02x"%eval(z) for z in binout.split()]),''.join([cdot(eval(z)) for z in binout.split()]))


____________________


chungy
Member
Level: 31


Posts: 134/174
EXP: 168466
For next: 16897

Since: 08-04-07


Since last post: 14.1 years
Last activity: 13.9 years

Posted on 01-28-08 10:26:04 PM Link | Quote
I just realized that an old message board I made out of boredom was less than 8K total, not counting the README and database initialization script. here (Warning: the source doesn't look very good...)
Rena
I had one (1) message in Discord deleted and proceeded to make a huge, huge mess about how it was a violation of free speech and how moderators are supposed to be spam janitors and nobody should have the right to tell me not to talk about school shootings
Level: 135


Posts: 2212/5390
EXP: 29079571
For next: 255434

Since: 07-22-07

Pronouns: he/him/whatever
From: RSP Segment 6

Since last post: 343 days
Last activity: 343 days

Posted on 01-29-08 12:20:32 AM (last edited by HyperHacker at 01-28-08 09:21 PM) Link | Quote
Jul - Post #2212 - 01-28-08 07:20:32pm
Incomplete screenshot app: main.cpp, main.h for a total of 9,346 bytes. If you took out all the big comments and whitespace it'd probably fit in 8K.

If you want something that's already < 8K, I could post a simple crappy old experimental app that shows the system uptime, but meh.

____________________
Next newer thread | Next older thread
Jul - Computers and Technology - Let's Programming ~ No bigger than 8KB of code! New poll - New thread - New reply


Rusted Logic

Acmlmboard - commit 47be4dc [2021-08-23]
©2000-2022 Acmlm, Xkeeper, Kaito Sinclaire, et al.

29 database queries, 2 query cache hits.
Query execution time: 0.080818 seconds
Script execution time: 0.011616 seconds
Total render time: 0.092434 seconds