Possible duplicate:<<and → → in C ++
I don’t quite understand what this means ... I am just learning C ++ from my very very basic Python experience ... and so this can be a very stupid question. My question is ... let's say you have your classic Hello World program and you have a line:
cout<<"Hello World!"<<endl;
which means <means ... because I was just looking at using input in C and seeing that you would do something like:
int i; cin>>i;
and I noticed that it has → instead of <<and I read that these are bitwise shifts ... and I don’t quite understand what it is ... but I think it could be different here ... Help ... thanks in advance
++ . ++ ( , +, - *), , :
+
-
*
Foo x = 100; Foo y = 200; x = x + y;
++ IOstreams C stdio.h, printf. << >> " " " " . , :
stdio.h
printf
<<
>>
std::cout << "Hello world";
... "Hello World" cout, . - - , , (, ..).
"Hello World"
cout
. .
: 10 = 1010 (8x1 + 4x0 + 2x1 + 1x0).
.
Left shift: 10100 and that (16x1 + 8x0 + 4x1 + 2x0 + 1x0) or 20. You multiplied by two! Right shift: 101 (4x1 + 2x0 + 1x0) or 5. You divided by two!
2.
, cin i:
"Hello world" , cout:
Source: https://habr.com/ru/post/1794838/More articles:How to write a line starting with '=' in a cell using a table: WriteExcel - perlQuestion with Ti-83 emulator with ROM - c ++echo from php "how does it go" - echoUnclosed INDENT on line 6 (CoffeeScript) Compiler Error - javascriptДругая ошибка CoffeeScript - javascriptHelp needed to distinguish between WebMatrix, ASP.NET web pages, and Razor syntax - asp.net-mvc-3jQuery переключает строки таблицы с файлами cookie - jqueryVS2010 не открывает файлы при открытии решения - visual-studio-2010jQuery switch with cookies: how to get default minimized state and stay accessible? - jquerySetting New Cookies on CakePHP - CookiesAll Articles