I'm trying to read from a text file such as "the apple does not fall far from the tree" where each letter has a random assigned string value such as a=01000, b=00010, and so on. Also the spaces have value 99999. The text file needs to be translated to these string values. I cant figure out how to convert the spaces to their string value and get the text file to read straight through properly including the spaces. I've created if statements for each character that should convert them to strings but it still won't run correctly. I think I'm not reading the text file right somehow. Any feedback appreciated.