Module: (C++) Recursion


Problem

10/12

Number to hexadecimal number system

Theory Click to read/hide

Useful information
English letter 'A' has the code 65.
The record char c = 65; stores the English letter A in the variable c.
Thus, you can get the desired letter by its code.

Problem

Write a recursive procedure that converts a number to hexadecimal. 

Input
The input to the program is the number N (N <= 4096) - a number in the 10th number system.

Imprint
Display one number on the screen - a number in hexadecimal number system
 
Examples
# Input Output
1 123 7B