I don't know where to post this, and this forum seemed to be the best place.

I have a project for school, where basically, I'm given a file that's a dictionary of 1,000 words, and after that, contains N number of lines of text that's encrypted. All of the encrypted sentences only use the words found in the dictionary, and each sentence uses a different encryption scheme.

It's my task, obviously, to try to decrypt these sentences.

So I'm looking for some ideas about how to do it.

One method I've already tried is to run some simple statistics on the dictionary, and tally up how many times each letter of the alphabet occurs, then do the same thing with my encrypted sentence.

So I would know that e appears 867 times in the dictionary and has the highest occurance, and z appears 8 times as the highest occurance in the sentence, I replace z with e, and everything else with dashes (-). Then I compare each word in the sentence to the dictionary, to make sure they still match. If everything's good, I go on to the next letter.

The problem arises when a replacement is made in the sentence, and every word still matches the dictionary, but is in correct.

I've also tried converting each word to numbers, such as:

zfzrqatx would be
1213456

And look for patterns in the dictionary that match that number scheme, but if each word in the sentence is three letters long, this method isn't going to be very efficient, either.

So any suggestions, help, or examples would be welcome.