output.WriteLine($"{Convert.ToString(num1, 16).PadLeft(width)}");
The above code outputs the integer converted to hexadecimal. The 'width' variable is a variable that takes a value from the keyboard to determine how to align the numbers. When printing hexadecimal numbers, I want to print the alphabet in uppercase.
I've done a google search with several words but couldn't find a way to tell this. I need to use the Convert.ToString function because I need to use the 'width' variable to enter the number of spaces to align the characters with. If anyone knows how to fix this, please help.
When I asked the question, I was mistaken and asked the question incorrectly in octal. It's corrected.
I want to print '94e' in the picture above as '94E'.