 | | Sometimes a single program must be able to manage several file descriptors, acting immediately on any input received from them, and yet also performing other computations when no input is received. For example, consider a multi-player Star Trek game. While none of the players are typing, the program must draw the ships, planets, and so forth, and move them about on each player's screen. But when a player types a command (such as turn left), the program must immediately receive that input and act on it. | |
|