HW_2_TurnIn_Kyle_Busdieker

In C++ while loop syntax is just the same as in Java. You probably want two separate lines:
int i = 0;
while( i < n){