Home Segments Index Top Previous Next

329: Mainline

When you decide to stop the loop, assuming that you are working with a typical version of the Unix or Dos operating systems, you can arrange for the input expression to return 0, instead of the value of cin, thus stopping the while loop, by typing the appropriate keychord.

You are said to type a keychord whenever you hold down one key while you press another. For example, if you are working with a typical version of Unix, you tell the input operator to return 0 by holding down the control key and pressing the d key, thereby typing the control-d keychord.