Question: Please include extensive comments. Question 1. Characters Merge (50 points) Write a C program to accept two string letters input and merge them as an

Please include extensive comments.

Please include extensive comments. Question 1. Characters Merge (50 points) Write a

Question 1. Characters Merge (50 points) Write a C program to accept two string letters input and merge them as an ascending alphabet string and display it on screen. Suppose two input string letters have been sorted as ascending order already. For instance, abcdef is a string letter on its ascend order and neither bacdef nor abcdfe is qualified; Also, either Aa or Ab is an alphabetically ascending while neither aA nor bA is. You only consider arn ascending string for input. Design a function to merge these two characters into one according to ascending order. Name your program file Hw4_q1_code.c. Requirements are following: Not allowed to use any library function in head files that merge two strings or sort a string directly in an alphabetical order. You can use library functions within the scope of , and . Write the merge function by yourself. You can use scanf/gets function to accept input. 1. 2. Sample input: Please type in 1st characters: abcdef Please type in 2nd characters: bcefghi Sample output: After merge: abbccdeeffghi Please type in 1st characters abcdef Please type in 2nd characters: bcefghi After Merge: abbccdeeffghi Hint: char a, b. Figure out a mechanism deciding which one is bigger. See Professor's Ch5 slides. Understand what ASCIl is and how a C string terminates

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 Databases Questions!