Lesson 2: Variables, Cycles, Conditions... Exercise 1: Now you are going to make your first game! The task is to guess number. Player can try to the find the correct number 8 times. This is how the game should look like: Generating new number... done. Insert a number: 23 Too high! Insert a number: 12 Too low! Insert a number: 20 Too high! Insert a number: 18 You win! A bit of tip: This little software is able to generate a random number between 0 and 100: ---- #include #include #include int main (void) { int numb; srand (time (NULL)); numb = rand () % 100; printf ("%d\n", numb); return 0; } ---- Exercise 2: We are member of the "important free software" audio player community. We have decided to change a progress bar so everybody must propose a new one with a little C source code. The progress bar should look like this: [ |--------------------------------> | sec: 121 of 250 ] The software must show an animated progress bar. You can use "usleep (300000);" to stop the execution of your software for 1/3 of second (without usleep your software will be too fast). The best progress bar will be integrated into our "important free software player". ---- #include #include int main (void) { printf ("Hello\n"); usleep (300000); printf ("World\n"); return 0; } ----