Question: Goal: Learn how to use the strcmp function to compare two C - strings. Assignment: Implement a function named stringorder that takes two C -

Goal: Learn how to use the strcmp function to compare two C -strings.
Assignment: Implement a function named stringorder that takes two C -strings, word1 and word2, as arguments and returns nothing. The function should print "First comes first" if word1 is
lexicographically smaller than word2, "Second comes first" if word2 is lexicographically smaller than word1, and "Words are equal" if both strings are identical.
Note: You can use the functions defined in th
Goal: Learn how to use the strcmp function to

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!