1) You need to escape all of your backslashes. (Remember, backslash is a special character in strings)
So it should be inputfile.open("C:\\Users\\Caitlyn\\Desktop\\42.txt");
2) You haven't declared the numbers variable (line 10, 12). Did you mean to put number?
3) Line 14: it should be inputfile, not inputFile.
4) It might work for your compiler without it, but technically, to use system(), you need to #include <cstdlib> . Either way, it's generally not recommended to use that function anyways. Here's why: http://www.cplusplus.com/forum/articles/11153/
Tip: Actually read all of your compiler errors. They'll usually help you pinpoint where the errors in your code are coming from.