Write a subroutine that takes a numeric value from 1 to 9 as an argument and then returns the English name (such as,
). If the value is out of range, return the original number as the name instead. Test it with some input data; you'll probably have to write some sort of code to call the subroutine. (Hint: the subroutine should
perform any I/O.)
Taking the subroutine from the previous exercise, write a program that takes two numbers and then adds them together, displaying the result as
. (Don't forget to capitalize the initial word!)
Extend the subroutine to return
. Try it in a program.