int val, total = 0;

for (int i = 0; i < 10; i++){

cin >> val;

total += val;

}

i의 값이 어떻게 val에 대입되는건가요?