Nested While loop not counting two files correctly

I am working on a program that takes a file in from the command line. this file is then compared to a text file to see if it has certain words in it. if it does, i want it to increment a counter for each time that certain word is found. I thought I was… Read More Nested While loop not counting two files correctly