Pressing size with C

xiaoxiao2021-03-06  41

#include "stdio.h" #include "stdlib.h" #include "time.h"

Void guess ();

Main () {Printf ("You Have 10 $. / N"); guess ();

Void guess () {INT NUM = 0, TEMP = 0; int m = 10; CHAR C; DO {SRAND (Time (NULL)); Num = rand (); Num = Num% 2 1; Printf ("please Press B or S: "); c = getChe (); c == 'b'? Temp = 1: (c == 's'? Temp = 2: EXIT (1)); if ((Temp == Num) ) && (temp == 1)) M = 8; if ((Temp == Num) && (TEMP == 2)) M = 4; if (Temp! = NUM) M- = 5; Printf ("You Have % D $ / n ", m);} while ((temp == 1) || (TEMP == 2));

转载请注明原文地址:https://www.9cbs.com/read-56762.html

New Post(0)