Question: please solve the question in the first pic in C language. Again, please only solve the question in first pic. the second pic (project 2

please solve the question in the first pic in C language. Again, please only solve the question in first pic. the second pic (project 2 task1) is only for provide more details to solve the question in first pic. Thanks.

please solve the question in the first pic in C language. Again,

project 2 task 1 is this one below, don't solve this question. please solve the question in the first pic. Thanks.

please only solve the question in first pic. the second pic (project

Modify Project \#2. Task \#1 so that input characters are command line arguments. Requirements - Name your program project5_encode.c. - Input characters are command line arguments. There can be any number of command line arguments. - Assume the total number of input characters is no more than 1000. - Character handling library functions in ctype.h are allowed. - The program should include the following function: void encode(char *input, char *output); - The function expects input to point to a string containing the string to be encoded, output to point to a string containing the result. - The program should also check if the number of arguments on the command line is greater than or equal to 2 . If the number of arguments is 1 , the program should display the message "Invalid input!". Task \#1 - Encode a string (50 points) Task Write a program that encodes the input characters using the following algorithm. - if the input character is a digit (' 0 ' through '9'), then output the digit by adding 6 to the digit and calculate the remainder by 10 . For example, if a digit is ' 6 ', then replaced digit is ' 2 '. Subtract the digit with ' 0 ', add 6 , and then calculate the remainder by 10 , then add ' 0 '. - If the character is an alphabetic letter, then shift the letter by 6 . For example, if the letter is ' B ', then the letter becomes 'H'. Subtract the letter with ' a ' (for lower case) or ' A ' (for uppder case), add 6 , and then calculate the remainder by 26 , then add ' a ' (for lower case) or ' A ' (for uppder case). For example, ' X ' shifted by 6 is ' D '. - If the character is a white space, skip it. - If the character is not a digit, an alphabetic letter, or a white space, output the underscore ' ' character. Requirements 1. Follow the format of the examples below. 2. Use getchar() function to read in the input. Do not use scanf. 3. The user input ends with the user pressing the enter key (a new line character). 4. Character handling library functions in ctype.h are allowed

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!