Skip to content

Instantly share code, notes, and snippets.

@ConorOBrien-Foxx
Created March 23, 2017 00:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ConorOBrien-Foxx/06b3e113bd68a8d637fb2c59340d3200 to your computer and use it in GitHub Desktop.
Save ConorOBrien-Foxx/06b3e113bd68a8d637fb2c59340d3200 to your computer and use it in GitHub Desktop.
Who says programming isn't human readable? This reads like a book!
#include <iostream>
#include <stdlib.h>
#define CLEAR std::cout<<"\033[2J\033[1;1H";
#define FOR for(int
#define IN =
#define TO ; i <
#define EACH ; i +=
#define DO ){
#define END ;}
#define CHARACTER char
#define nextline std::endl
#define RETURNS
#define AN
#define A
#define the
#define AND
#define BY
#define THE
#define REQUIRES (
#define OF
#define IS
#define IT
#define LESS <
#define GREATER >
#define THAN
#define LIST *
#define PI 3.14159265
#define Q(x,y) if(x)return(y);
#define WHILE while(
#define MAIN int main(int argc, char**argv){
#define MAXIMAL(x,y) ((x)>(y))?(x):(y)
#define NOTHING void
#define DECIMAL double
#define NUMBER int
#define DOES ){
#define GIVES ){return
#define ENDFUNC );}
#define moveto printf("\033[%d;%dH%s\n",
#define place ,
#define ACCORDINGLY ;}
#define IF ;if(
#define THEN ){
#define GIVE ;return
#define negative -
#define ALTERNATIVELY ;}
#define OTHERWISE ;}
#define INTO >>
#define READ
#define INPUT std::cin
#define EQUIVALENT =
#define EQUALS ==
#define EQUAL
#define DICE srand(radius);
#define THROW
#define OR
#define WITH
#define THING
#define AROUND %
#define PLUS +
#define TWO 2
#define ONE 1
#define ZERO 0
#define FIVE 5
#define TWOPOINTFIVE 2.5
#define MAGIC [2] = {(char)i};
#define TIMES *
#define RANDOM rand()
#define LOWER -= 1;
#define HIGHER += 1;
#define OVER /
#define FORTY 40
#define THREESIXTY 360
#define NINETY 90
#define CONSTANT 40500
#define ONEEIGHTY 180
#define FOUR 4
#define NINETYFIVE 95
#define THIRTYTWO 32
RETURNS NOTHING PRINTAT
REQUIRES
A NUMBER x,
A NUMBER y,
AND A CHARACTER LIST c
AND IT DOES
moveto x, y AND place c
ENDFUNC
RETURNS DECIMAL SIN
REQUIRES A DECIMAL x
AND IT DOES
IF x IS LESS THAN ZERO THEN GIVE -SIN(-x)
ALTERNATIVELY
IF x IS GREATER THAN ONEEIGHTY THEN GIVE SIN(x - THREESIXTY)
OTHERWISE
GIVE FOUR * x * (ONEEIGHTY - x) OVER (CONSTANT - x * (ONEEIGHTY - x))
ACCORDINGLY
RETURNS DECIMAL COS
REQUIRES A DECIMAL x
IT GIVES A SIN(x - NINETY) ACCORDINGLY
MAIN
NUMBER radius;
READ INPUT INTO radius;
THROW A DICE
CLEAR
NUMBER skew IS EQUIVALENT WITH TWOPOINTFIVE;
WHILE radius IS GREATER THAN OR EQUAL WITH ONE DO
NUMBER i IS EQUIVALENT WITH A RANDOM THING AROUND NINETYFIVE PLUS THIRTYTWO;
CHARACTER c IS MAGIC
FOR i IN ZERO TO THREESIXTY EACH MAXIMAL ( ONE , FORTY OVER radius ) DO
PRINTAT (
radius PLUS skew PLUS radius TIMES COS(i),
radius PLUS skew PLUS radius TIMES SIN(i),
c
)
END
radius IS LOWER
skew IS HIGHER
END
END
@teward
Copy link

teward commented Mar 23, 2017

... does this actually work? o.O

@ckjbgames
Copy link

I'm pasting all these definitions onto a header file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment