.


:




:

































 

 

 

 





..

 

 

 

2016

  ..
  : . -, 2008.

 

 

, , . , , , .

 

. ++ , .

, , , . Windows, API , MFC ATL, . STL. - .

, . .

 

 

1 2 . . ++. , 9 , 3 .


.. 8

1. 8

1. ++. 8

1.1. ++.. 8

1.2. .. 10

1.3. . 13

2. ++. 17

2.1. , . 17

2.2. . 18

2.3. . 19

2.4. .. 22

2.5. . 29

2.6. . 43

2.7. ++.. 46

3. .. 51

3.1. . 51

3.2. . 62

.. 67

.. 68

. 74

... 74

2. 74

4. ++. 74

4.1. .. 75

4.2. . 76

4.3. . 80

4.4. . 86

4.5. . 91

5. , , , .. 95

5.1. . 95

5.2. , . 97

5.3. void*. 107

5.4. cout 110

5.5. . 111

5.6. , , .. 115

.... 126

.. 126

. 130

... 130

3. 130

6. , , .. 131

6.1. , . 131

6.2. . 137

6.3. . 141

6.4. (-) . 143

6.5. .. 144

6.6. . 157

.. 164

.. 166

. 167

4. 168

7 , ... 168

7.1 . 169

7.2 ++.. 177

7.3 . 185

7.4 . 188

7.5 . 190

7.6 . 195

7.7 () . 204

7.8 , - operator=() . 210

7.9 . 215

7.10 .. 220

.. 223

.. 223

. 227

5. 227

8 .. 227

8.1 . 227

8.2 .. 241

8.3 .. 245

8.4 .. 256

6. 257

9 (STL) 257

9.1 STL. 257

9.2 .. 260

9.3 .. 261

9.4 .. 266

9.5 .. 267

9.6 .. 268

9.7 . 272

9.8 . 275

9.9 . 276

9.10 . 278

9.11 .. 280

9.12 .. 283

9.13 . 288

9.14 . 288

... 292

1. 292

ASCII 292

2. 298

. 298

 


 

 

++ (Bjarne Stroustrup, ) 80- . . , , , ++ ( ++ ), , - .

80- ++ . 1985 1989 1998 . (STL), (namespaces), (RTTI), (cast ) , . , , , .

 

1

++, .

1. ++

1.1. ++

, ++, !.

// 1.1 hello.cpp //1

#include "stdafx.h" //

#include <iostream> //2

void main(){ //3

std::cout<<"\n Hello World!"; //4

getchar(); //

}

. ++ . //, , , . :

// .

, \* * \. :

\*

*\

#. , . include (). iostream.h. *.h ++ . < >, iostream.h, , , , INCLUDE. iostream.h , , cout ( cin, err .) iostream. . , cout (<<) , include iostream.h.

, ++, main ( WinMain). . , main, :

_ _( ) { }

_ ( main - void); _ ( main); - , ( ); , ++ ( , ).

cout << \n . cout , , . :

cout<<\n 5+3 = <<(5+3);.

, main. .

 

, , ++, - , . , , *.txt *.cpp, *.c *.h.

, , Borland Microsoft Visual, . , , , , , .. , (), *.exe. . 1.1.

. 1.1.

 

, ( , #). , hello.cpp include. iostream.h. .

(Compiler), , *.obj, . , , message , , , . 90% , .

. , , . , , , , . , .

Linker () , . , , . , , . , .

. Borland Compile . Link , . Build all .

 

++ , , . , ++, . . . 1 0 16 .

1.1





:


: 2018-10-15; !; : 346 |


:

:

, .
==> ...

1805 - | 1636 -


© 2015-2024 lektsii.org - -

: 0.036 .