/home/toolbox/public_html/solutions/115/11597/a.c
1 #include <stdio.h>
2 #include <string.h>
3 #include <sys/types.h>
4 #include <sys/stat.h>
5 #include <fcntl.h>
6 #include <stdint.h>
7 #include <math.h>
8 #include <stdlib.h>
9 #include <ctype.h>
10
11 #define TRUE (1 == 1)
12 #define FALSE (1 != 1)
13
14 #define DEBUG if (FALSE)
15
16 /*
17 * Author: Isaac Traxler
18 * Date: 2021-11-05
19 * Purpose: fun
20 * Problem: 11597 - Spanning Subtrees
21 */
22
23 /*
24 * This template reads data until a terminating value is reached.
25 */
26
27 int num;
28 int cnt;
29
30 void init()
31 {
32 /* FUNCTION init */
33 cnt = 1;
34 } /* FUNCTION init */
35
36 void dump()
37 {
38 /* FUNCTION dump */
39 } /* FUNCTION dump */
40
41 int getInput()
42 {
43 /* FUNCTION getInput */
44 int dataReadFlag;
45
46 scanf(" %d ", &num);
47 dataReadFlag = (0!= num);
48 return (dataReadFlag);
49 } /* FUNCTION getInput */
50
51 void process()
52 {
53 /* FUNCTION process */
54 printf("Case %d: %d\n", cnt, (num / 2));
55 cnt++;
56 } /* FUNCTION process */
57
58 int main()
59 {
60 /* main */
61 int moreToDo;
62
63 init();
64 moreToDo = getInput();
65 while (moreToDo)
66 {
67 /* while */
68 process();
69 moreToDo = getInput();
70 } /* while */
71
72 return EXIT_SUCCESS;
73 } /* main */
74