I'm really new to PEP/8 and am having a bit of a hard time for a practice lab for my course. The goal is to ask user to input 2 hexadecimals to add or substract under the form HHHH+FFFF or HHHH-FFFF (no other input is accepted)
According to my teacher, I need to make my code read character by character out of the user input and then perform the calculation depending on the symbol in 5th position. How do I go about doing that?
Also, I cannot seem to find a way to add or substract hexadecimals directly, do I have to translate the HHHH and FFFF to decimal, then perform the calculation on the decimal numbers then translate back to hex for output?
Lastly, in my basic welcome message it is supposed to print out "Please input your calculation:" but the terminal always prints "Please input your calculation: A"...why does an A appear?
For the last part, my code is:
Br main
hello_ms: .ASCII "Please input your calculation: "
main: stro hello_ms, d
stop
.end