Like UNIX's Fortune program, with the following requirements:
- Obtain number of entries.
- Generate random val based on (1).
- Fetch random item.
- Output phrase.
On
srccode.
- Arrays decay to pointers to the first element in the array in
C. - You cannot pass
argv[]without pointer since it would not know the size at compile time. char *argv[]standard decleration for receiving command-line arguments inC.strftime()can be used instead ofprintfto print strings with time vars.