Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Below is the format of the program Using pointers Your task Your task in this assignment is to create your own versions of the most

image text in transcribed
Below is the format of the program
Using pointers
image text in transcribed
Your task Your task in this assignment is to create your own versions of the most commonly used standard string functions. Specifically, you should create these functions: find string length int mystrlen(const char 's) e determines the length of the string s. Returns the number of characters in the string before the e string comparison int mystrcmp(const chars1, const char s2) e compares the string s1 to the string s2. The function returns 0 if they are the same, a number 0 if s1s2 string copy char "mystrcpy (char "s1, const char 's2) copies the string s2 into the character array s1. The value of s1 is returned. string concatenation char "mystrcat(char s1, const char 's2) e appends the string s2 to the end of character array s1. The first character from s2 overwrites the e of s1. The value of s1 is returned. Caution Your functions should NOT call any of the built-in string functions. In the context of this . assignment, you should pretend that the built-in string functions do not exist e You should pay special attention to boundary cases. In particular, make sure that your functions work when given empty strings as arguments. For example, make sure that the function call mystrlen() returns 0 functions, that is, a set of function definitions. mystrlen function: e You just need to create a header file named proj3.h containing the implementation of the four You may use array notation to define your functions. For example, this is an acceptable version of the

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Driven Web Sites

Authors: Joline Morrison, Mike Morrison

2nd Edition

? 061906448X, 978-0619064488

More Books

Students also viewed these Databases questions

Question

1. Diagnose and solve a transfer of training problem.

Answered: 1 week ago