TOPIC

Dúvida EOF c++

gneri1 asked 5 years ago

Como colocar esse EOF em c++?

This topic was solved and cannot recieve new replies.

  • gsanchez0 replied 5 years ago

    pode ser

    while(scanf("%d %d %d", &A, &B, &C) != EOF)

    o

    while(scanf("%d %d %d", &A, &B, &C)  == 3)

    ou se você fizer isso com cin, poder ser

    while(cin >> A >> B >>C)