You mean, how to identify each letter with it's corresponding morse code?
You could write a function (if you've learnt about them, that is), that does the conversion.
Or, and I'd say this is simpler, have the character's ASCII codes identify the correct block of the morse code array. So that the code['o'] would store the "---" string, and code['s'] would store "...", and so on.
Then you could simply just read the next character, and you'd immediately know the position of the corresponding morse code in the array.