After reading a file in and assigning each letter to a specific integer value, how would I then convert the read-in string into the initialized integers as seen below?
A = 20
B = 30
C = 40
D = 50
The file has the following data: B D C A C A D B
How do I then convert the letters read in from the file into the numbers? For example, if I read B in, how would I convert it into 30?