codepad
[
create a new paste
]
login
|
about
Language:
C
C++
D
Haskell
Lua
OCaml
PHP
Perl
Plain Text
Python
Ruby
Scheme
Tcl
/* map.h */ #define MAP_H void display(const int *p, int width, int height); /* display.c */ #include <stdio.h> static const char *symbols = " #???@"; void display(const int *p, int width, int height) { int w, h; for (h = 0; h < height; h++) { for (w = 0; w < width; w++) putchar(symbols[p[h * width + w]]); putchar('\n'); } }
Private
[
?
]
Run code
Submit