Hi guys I thought that when using a loop or a test condition I thought you could only test if a condition is true or not for example if(x == 20) or while(y==true) but I didn't know you could you statements in it like cin >> x; how come this is allowed?? coming from Java it does not make a whole lot of sense to me,could someone explain why this is allowed or how it works thanks
1 2 3 4 5 6 7 8 9 10
#include <iostream>
usingnamespace std;
int main()
{
int x;
while(cin >> x){
}
}