We assume a 'table' where we can store up to MAXSIZE (a defined constant) strings. We assume that each string in the table will have length less than MAXLENGTH (a defined constant). Thus table can be declared as:
char table[MAXSIZE][MAXLENGTH];
Here is an example of the interactions in a possible run:
Enter line [CR to exit] : Roses are VERY red Enter line [CR to exit] : VioLETS ARE Blue Enter line [CR to exit] : and Blue ARE Enter line [CR to exit] : roses are very red violets blue andFinally the program prints out again these tokens, but now in sorted order, i.e.
and are blue red roses very violetsAs a comment at the beginning of your program you should do a case analysis for this problem: problem statement, analysis, design, and testing.