Question: Q 1 Char type and operations Write C programs mychar. h and mychar. c , containing the headers and implementations of the following functions. /

Q1 Char type and operations
Write C programs mychar. h and mychar. c, containing the headers and implementations of the following functions.
/**
Determine the type of a char character.
@param c - char type value
@return - O if c is a digit, 1 if c is an arithmetic operator, 2 if c is an E
*/
int mytype(char c)
??****
Flip the case of an English character.
Cparam c - char type value of ASCII code of English letter.
@return - c's upper/lower case letter if c is a lower/upper case English le
*
Convert digit character to the corresponding integer value.
Qparam c - char type value of ASCII code of digit charactor.
@return - its corresponding integer value if c is a digit character.
*/
int char_to_int(char c)
Test your programs using provided public test main program mychar ptest.c and terminal commands shown in the following public test. The screen output should be like as shown after the test run command.
Public test
compile command: gcc-std=c99 mychar.c mychar_ptest. c -o q1 test run command: q1
Test: mychar
Char ASCII MyType
2,50,0
 Q1 Char type and operations Write C programs mychar. h and

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!