I have a homework that I've spent almost 1 week but still can not solve. Please help me! I tried my best! I've just started studying Character and String, so this homework could not be complicated. Thanks a lot!!! I'm really frustrated.
Write a program that prints all command line arguments (not including program name) in reverse order, and each in reverse, or “no arguments given” if there are no arguments. For example:
./foo hello world 123
321 dlrow olleh
no argument given
Hint: _ Functions containing
+ void reverse_string (char* s)
+ int string_length (char* s)
_ Do not use any automatic functions like strlen() or strrev()
_ Main should be about 5-7 lines, reverse should be about 5-7, and length should be about 2-3.