upt-pt-labs/lab04/test.c

22 lines
433 B
C
Raw Normal View History

2016-04-11 17:00:29 +00:00
#include <stdio.h>
enum cardsuit {
CLUBS = 1,
DIAMONDS = 2 ,
HEARTS = 3 ,
SPADES = 4
2016-06-22 11:05:29 +00:00
} custom_deck [ 52 ];
2016-04-11 17:00:29 +00:00
struct {
unsigned int age : 3;
unsigned int dayWeek: 3;
unsigned int flagValid : 1;
} Info;
int main() {
unsigned int aux;
scanf ("%u", &aux);
if (aux == 0) Info.flagValid = 0; else Info.flagValid = 1;
if (aux > 1) fprintf(stderr , "Sir , You should be more careful with your input!\n");
return 0;
2016-06-22 11:05:29 +00:00
}