EECS 183 Lecture Notes - Lecture 4: Return Type, Duplicate Code, Semicolon
![EECS 183 Full Course Notes](https://new-docs-thumbs.oneclass.com/doc_thumbnails/list_view/2160099-class-notes-us-um-ann-arbor-eecs-183-lecture7.jpg)
1
EECS 183 Full Course Notes
Verified Note
1 document
Document Summary
When datatype of value read doesn"t match datatype of variable. No reading takes place again until cleared the state. #include using namespace std; int main () string message; cin >> message; cout << message; return 0; We need to include the string library. Stops at the first trailing whitespace, which is not consumed, but remains waiting in the input stream. To read a strings that includes white space (eg: hello world ) Then read pointer proceeds to after is not put into the string. Cin >> combined with getline ( ) Skips (reads and discards) char"s in the input stream. A function is a list of statements that can be executed by referring to the. An input value to the function appears between ( ) The function executes and returns a new value. A section of a program that can act on data, and returns a value. Every function you would ever want doesn"t already exist.