3

How do you pronounce the << operator?

For example it is used in here.

2
  • I pronounce it just like it's spelled.
    – Owen
    Commented Jan 29, 2016 at 16:22
  • 1
    The link you provided has the pronunciation. << is pronounced "insertion operator". >> is pronounced "extraction operator".
    – 425nesp
    Commented Apr 14, 2022 at 16:45

2 Answers 2

3

In the context of iostreams, writers often will refer to << and >> as the “put-to” or "stream insertion" and “get-from” or "stream extraction" operators, respectively* .

If you are using << for output in C++ programming then I would just call it "put-to".

(Otherwise, that would also be used as the bitwise left shift in binary operations, but I doubt that is what you meant)

2
  • One cannot use << for output in C programming. If you mean C++, say it; this C/C++ thing is a myth that does not exist.
    – tchrist
    Commented Aug 3, 2013 at 13:07
  • 2
    actually I say to and from backwards to that: "cout << x" would be "cout from x" and "cin >> y" would be "cin into y". I agree about insertion and extraction though. Commented Aug 3, 2013 at 15:22
3

Just found following in TC++PL 3rd Edition page 25, for your reference.

The << operator (“put to”) is used as an output operator; cout is the standard output stream. The >> operator (“get from”) is used as an input operator; cin is the standard input stream. The type of the righthand operand of >> determines what input is accepted and is the target of the input operation. The \n character at the end of the output string represents a newline.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .