Jun-27-2018, 08:42 PM
You are still checking every word for every word. You loop through pear and cherry. The first loop is for pear. And in that loop you check for both pear and cherry. The second loop is for cherry, and in that loop you check for both pear and cherry again. You need to change your if statement to be like Sudhakar's, so it only checks the word for the current loop.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures