8
Answers

A C program, assuming that the string.h doesn't exist?

Ask a question
Lisa b

Lisa b

11y
2k
1

Assume that the <string.h> library does not exist.  Write your own string functions called stringcopy, stringlength, stringcat and stringcompare.  These functions must perform the same operations as strcpy, strlen, strcat and strcmp.  Note that these functions do not read strings from the screen and do not display strings on the screen.  This must be carried out by main.


Then write a program to test these functions by selecting choices from the following menu:

 

A. Test the stringcopy function

B. Test the stringlength function

C. Test the stringcat function

D. Test the stringcompare function

Q. Quit

 

You must decide what happens when each option is selected.


Answers (8)