in this segment of code
why do they include !cin and what does it mean? does it just mean "not num1" or is cin different from num1??
loopCount = 1;
Here, you can enter several integers, separated by spaces. Only the first integer will be read though, but since the whole block is looping the rest of the numbers will also be read (in the next loops).
Probably, cin returns 0 when there are no more numbers to read, thus exiting the loop.
!cin will exit when a read error flag, or EOF, is detected. As Magos suggested, it appears that its primary purpose is to detect the EOF flag, but will exit if the data/file is corrupted in some way, as well.