The >> operator reads formatted input from files just like from cin. It skips whitespace and reads until the next whitespace. Use file >> variable; to read one value at a time. Reading multiple values works naturally: file >> x >> y >> z; reads three values in sequence.
The operator returns the stream, so you can chain reads together. The >> operator works with all basic types: int, double, string, char. For strings, it reads single words only. Use getline for full lines.