#include "blike.h" main() { int a, b, c; cls(); b = 0; c = 1; for (;;) { locate(2, 2); printf("%d %d\n", b, c); wait(10); a = inkey(); if (a != 0) { break; } b++; c++; if (b > 9) { b = 0; } if (c > 9) { c = 0; } } for (;;) { locate(2, 2); printf("%d %d\n", b, c); wait(10); a = inkey(); if (a != 0) { break; } c++; if (c > 9) { c = 0; } } if (b == c) { printf("あたり!\n"); } else { printf("はずれ\n"); } }
(This host) = http://osask.net