Skizz
  • Member for 10 years, 11 months
  • Last seen more than a month ago
Interpret brainf***
54 votes

16 bit 8086 machine code: 168 bytes Here's the base64 encoded version, convert and save as 'bf.com' and run from Windows command prompt: 'bf progname' gMYQUoDGEFKzgI1XAgIfiEcBtD3NIR8HcmOL2LQ/...

View answer
Obfuscated FizzBuzz Golf
23 votes

C++: 886 chars I've tried to hide the 'fizz' and the 'buzz'. Can you spot them? #include <iostream> #define d(a,b) a b #define _(a,b) d(#b,#a) #define b(b) _(b,b) #define y _(i,f)c #define x _(...

View answer
Determine if a number is divisible by 13 (without using 13 itself)
19 votes

ASM - 16 bit x86 on WinXP command shell executable - 55 bytes * 0.8 = 44 source - 288 characters * 0.8 = 230.4 The number 13 doesn't even appear in the assembled .com file. Assemble using A86. ...

View answer
Recreate a 'Snake' game in a console/terminal
10 votes

16 bit 8086 526 bytes / 390 bytes Decode this using a Base64 decoder and call it "snake.com" then execute from Windows command prompt. Tested on WinXP, you may need to use DosBox to get the right ...

View answer
Text compression and decompression — "Nevermore."
8 votes

8086 Assembler / MS_DOS Compressor: 155 jNiAxBCO2I7AM/+9/QW5AAGK2TPAq4rDqv7D4va6AQkz9lK0BrL/zSFadDK7 /f+DwwM733QNOTd19ThHAnXwid7r34k1iEUC6BMAtACKRQJr8AODxwPryrQC zSHrxFIz0ovGuwMA9/...

View answer
Decipher a Vigenère ciphertext
8 votes

MS-DOS 16bit .COM file - 87 bytes Base64 encoded binary (following this link for a decoder) v1cBi8/oQACJ/ovv6DkAi9msitAqF3MDgMI+gMJhgPp6dguA6jqA+lp2A4DqK80hO/...

View answer
99 Bottles Of Beer
7 votes

C I must have missed this question, so here's a version I posted as an answer elsewhere. It's a C quine based version. Compile and run to get next line of song. Repeat until bored. If code says "Time ...

View answer
Generating PBM bitmap files from ASCII text
6 votes

8086 Machine Code 190 Bytes (122 Bytes using BIOS) Here's Base64 encoded WinXP/MSDos .COM file: M8COwCaKDoUEitEmxD4MAaCAAP7IfliK8MHgA7cK9ve9egEAZ vy0APb3AUb6iMi0APb3AUb+x0YACg2DxQK+ggCK7qz24YvYJo ...

View answer
Print a Christmas Tree
6 votes

C This is Wade Tandy's C version but modified a little bit: ; int main( ){int i =-1,j=0,c =10;while(j ++<c){printf( " ");}{;printf( "...

View answer
Interpret Befunge-93
6 votes

16bit MSDOS .COM File - 1104 bytes This is Base64 encoded (decoder here), save decoded file as a .com and execute from command line with name of program file to run as the only argument. Tested in ...

View answer
What's my name? Produce the name of the language indirectly
6 votes

C Built using DevStudio 2005 #include <stdio.h> void main () { int i,j,i2; for (i=j=0,i2=200;i2<=200;i2-=19,j==putchar(32|(i2<'Q'&&i2>'+'&&(j<20||i<12||i>...

View answer
Koch Snowflake - codegolf
6 votes

MS-DOS 16 bit machine code: 199 bytes Decode using this site, save as 'koch.com' file and execute from WinXP command prompt. sCAAxo7ajsKLz/OquF9fulwvvUoBM9u+BADoiQDodgDocwDogADobQDoagDodwCK8TLSs0+...

View answer
Assembly Language Quine
4 votes

Windows .COM Format: 307 characters Assembles, using A86, to 51 bytes. Requires no external libraries other than the DOS Int21 AH=9 function (write string to stdout). db 185 db 51 db 0 db 190 db ...

View answer
How to determine if a number is odd or even without mod -or- bitwise operations?
2 votes

On a 68000 processor you could move a word value from the address defined by the value to test: move.l <number to test>,a0 move.w (a0),d0 ; it's even if the next instruction is executed and ...

View answer
Look and say sequence
2 votes

C: 213 characters main(){char*a,*b=calloc(' ',' '),*c=calloc(' ',' '),*d,*e,*f;*b='Q'-' ';for(a=" ";*a;++a){printf("%s\n",b);e=f=b;d=c;while(*e){while(*f==*e){++f;}d+=sprintf(d,"%d%...

View answer
Chessboard pattern
2 votes

C++ - 253 obfuscated characters #include <iostream.h> int main(int i,char*c[]=0) { char a=i,b=i>>8;i&32512?((i>>16&255)<a)?(cout<<b)?main((i^30720)+65536):0:(cout&...

View answer
Sort a list of numbers
2 votes

An enterprisey solution (in pseudocode): create sql connection create temporary table: one autoincrementing ID field and one value field convert array into xml post xml to sql database use stored ...

View answer
What's my name? Produce the name of the language indirectly
2 votes

Assembler Assembled using A86, generates a Windows .COM (tested on XP) inc cx push bx push bx inc bp dec bp inc dx dec sp inc bp push dx and al,72 mov ah,9 mov dx,si inc sp pop si pop cx int 21h ret

View answer
Remove vowels without using too many different characters
1 votes

ASM - 6 distinct characters 520 source characters (MsDOS .com) Assembled using A86 db 10110100xb db 00000110xb db 10110010xb db 11111111xb db 11001101xb db 00100001xb db 01110101xb db 00000001xb db ...

View answer
Calculate the total number of paths
1 votes

ASM - WinXP Command shell .COM 128 bytes, source = 607 characters To run, provide the rock id and the direction, e.g. program c1 where the letter is the rock (top left = a, bottom right = l) and ...

View answer
Carmichael Numbers
1 votes

C++ Machine i5-760 @ 2.8Ghz, only one core used Numbers found in 5 seconds: 129 #define WIN32_MEAN_AND_LEAN #include <windows.h> #include <iostream> using namespace std; bool IsPrime (...

View answer
What? No error?
0 votes

C or C++ Based on celtschk's answer:- int main (int argc, char *argv []) { return argc ["success!"]; } (yes, I have done that in production code, mainly to ensure people had read the code)

View answer
Coding in song - Representing music lyrics in a programming language of your choosing
0 votes

C - Bottles of Beer Compile and run this. Lyrics are put into the source code. Compile and execute output to get next line of song. When it says "Time to go...." then compile and execute with the ...

View answer
Write a self-replicating program.
0 votes

DOS COM File - 36 bytes 56 BE 80 00 AD FE C8 A2 10 01 7E 17 89 F2 88 74 02 B4 3C 33 C9 CD 21 72 0A 8B D8 B4 40 5A B9 24 00 CD 21 C3 Output file name is specified on the command line, truncated to 8....

View answer
Print largest integer you can with the fewest characters
0 votes

Windows x86 .com 8 bytes B4 02 B2 39 CD 21 EB F8

View answer
Generate the list [1, 0, -1, 0, 1, 0, -1, 0, ...]
0 votes

8086 Assembler (14 bytes of machine code): ; ax holds the index into the sequence ; returns the sequence value in ax a: inc al shl al,6 sar al,6 cbw xor al,ah add al,ah cbw ...

View answer
IPv4 Integer Conversion Function
0 votes

ASM - 98 byte executable (WinXP command shell), about 485 characters Assemble using A86. Badly formed IP addresses generate undefined output. mov si,82h mov di,10 mov bp,l3 fldz ...

View answer
Adding without using a + or - sign
0 votes

A very yucky C version Has no +, -, / or any digits. One use of * for a pointer type. The others (()=,) are needed a lot in the language itself. #include <malloc.h> #include <string.h> #...

View answer
Obfuscated Hello World
0 votes

Assembly: 117 source chars, 29 byte .com file Assemble using A86. mov si,273 mov ah,2 mov dl,133 lodsb add dl,al int 21h lodsb add dl,al jne 266 ret sbb ax,7 add si,[bx+di+6199] add di,dx clc pushf

View answer