Hi, I have an assignment where i have to write a C and assembly mixed-mode program.
- The c program takes in two characters which stand for two hex characters.
- The assembly procedure then passes each character in turn to a C function which determines if the character is a valid ASCII HEX digit (namely 0-F).
- If both characters are valid the assembly language procedure then compares the two HEX digits and returns the larger to the main program.
- The main C program then prints out the larger digit.
I am unsure how to do no. 2, namely, how to determine if it's a valid ASCII HEX digit or just garbage. Suggestions?