aboutsummaryrefslogtreecommitdiffhomepage
path: root/2048_clean.c
diff options
context:
space:
mode:
Diffstat (limited to '2048_clean.c')
-rw-r--r--2048_clean.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/2048_clean.c b/2048_clean.c
index 79a474b..cade2b4 100644
--- a/2048_clean.c
+++ b/2048_clean.c
@@ -177,15 +177,15 @@ void put_new_tile(void) {
int main(int argc, char **argv) {
srand(time(0));
- switch_to_alt_buffer();
- enable_raw_mode();
-
size = argc > 1 ? (*argv[1] - '0') : 4;
if (size <= 1 || size > 8) {
fputs("invalid board size\n", stderr);
return 1;
}
+ switch_to_alt_buffer();
+ enable_raw_mode();
+
put_new_tile();
put_new_tile();