Day 1:Introduction
1.1 Why use a language like C++
Conciseness
Maintainability
Portability
1.2 The compilation processsorce file>>>Prcessed code>>>Object file
1.3 General notes on C++
case sensitive
2.1 hello worldCpp代码
/*
* File: main.cpp
* Author: Gong Li
*
* Created on June 24, 2011, 9:18 PM
*/
#include <iostream>
using namespace std;
/*
*
*/
int main() {
std::cout<<"Hello,world!";
return 0;
}
2.2 Tokenskeywords, identifiers,literals, operators, punctuation, whitespace
2.3 Explaination
comment: //.... or /*....*/
#include: the preprocessor dumping in the content of another file.
int main(){}: execute when the program starts up
cout <<: outputting some piece of text
namespaces: like std includes a group of idemntifiers
strings: Hello, world!
escape sequence: ...
return 0: tell the OS it has completed successfully
3 InputInput cin >> x
Output cout << "hello"
补充:软件开发 , C语言 ,