Skip to content

Instantly share code, notes, and snippets.

@mikedanese
Last active December 14, 2015 06:49
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 mikedanese/5045545 to your computer and use it in GitHub Desktop.
Save mikedanese/5045545 to your computer and use it in GitHub Desktop.
typedef void (*function)();
char program[32];
int main() {
char *t = program;
unsigned i, n;
for (;;) {
for (i = 3; i; i--) {
n = getch() - '0';
if (n > 7) (*(function)program)();
*t = *t * 8 + n;
}
t++;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment