it looks like finished business to me but i will say it anyway....
using enumeration, for example
enum colors {RED, BLUE, YELLOW, GREEN} favouriteColor; you actually make an integer variable that can be assigned integer values using keywords you define. to make it simple:
#include <stdio.h>
enum colors {RED, BLUE, YELLOW, GREEN, ORANGE, VIOLET} favouriteColor;
enum shape {TRIANGLE, SQUARE, RECTANGLE ,CIRCLE, OVAL}
main ()
{
shape favouriteShape; // This is just a demonstration of second way to define a variable
favouriteColor = BLUE;
favouriteShape = SQUARE;
}
what enumeration actually does is making your code much more readable.
consider this:
favouriteColor = 1;
favouriteShape = 1;
and if you have tons of statements like these you will soon find yourself in mass of numbers where you dont know what numbers actually mean, and you would have to go to enumeration on the begining of the code to say: "Ah, yes...2 was YELLOW."
you cannot write something like:
printf ("What is your favourite color?");
scanf ("%d", favouriteColor);
and enter word RED on input, because facouriteColor is an integer.
you also cant use
scanf ("%s", favouriteColor); instead, because favouriteColor is far from being a string of chracters
if you want to use form you mentioned on the begining, something like: "What day is it?", you should use array of chars for input, and than compare it with constant strings: "Sunday", "Monday" ... using function
strcmp(string1, string2) , where strcmp evaluates (equals) 0 if they are the same, <0 if string1<string2 and >0 if string1>string2 is greater (by their ascii values). you can also use
strcmpl(string1, string2) , it is same as first one but doesnt take small and capital letters into account. i dont have any other methods for this on my mind right now.