Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@andreis
Created August 16, 2013 12:21
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 andreis/6249382 to your computer and use it in GitHub Desktop.
Save andreis/6249382 to your computer and use it in GitHub Desktop.
#include <stdio.h>
int i = (1 << 6) + 1; // 65 == 'A'
char *str;
int main()
{
for (str = "((((( ((((( \
((((( ((((| \
((((((((((((((((((((|)))))))| \
(((((((( (((( (|)))|((( \
(((((|)) )))) ))))))))) \
))))))))))))))))))))))))))))))))))\
)))))) )))))))))))))))))) ))))))))\
))|( ((((((((((((((( ((((( \
(((( ((((((((((((((( ((((( \
(((( (|(( ((((( (((( ((((( \
(((| )|( ((| ))) )))|( \
(((( ((((( \
\
(((((((((|)))))))))))))))|))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))|)))))))))))))))))))))))|";
*str; ++str)
switch (*str) {
case '(':
++i;
break;
case ')':
--i;
break;
case '|':
putchar(i);
break;
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment