.


:




:

































 

 

 

 





If() _1;

If() _1; else _2;

.

.

( ), _1.

.

( ), , { }.

.

if(x < 0) x = -x; else ++x; //

if(j > 0) {int k = 3; j = k;} // [5] k,

_1? _2: _3

_2, _1 , _3.

, x y : x = y > 0? y: -y;

Switch (_)

{ case _1: _1;

case _2: _2;

case _k: _k;

ëdefault: ;û }

switch case , .

, default, .

.

case.

break switch.

.

cout << ; cin >> digit;

Switch(digit)

{

case 0: case 1: cout << 0 1; break;

case 2: cout << 2; break;

default: cout <<

}

: goto ;

, ":";

.

: return ëû;

: break;

: continue;

for(ëû; ëû; ëû) ëû;

.

for(int i = 0; i < 10; i++) cout << i;

for(float x= -0.5; x < 0.6; x += 0.1) s += x;

While () ;

Do while();

-

/ C++ .

, , :

cin >> ë >> û;

:

cout << ë << û;

cin [6] cout [7] iostream.h.

/ :

setprecision(int n), n ;

setw(int n), .

iomanip.h.

math.h

int abs(int n)  
double sqrt(double x)  
double pow(double x, double y)  
double exp(double x)  
double log(double x)  
double log10(double x)  
double sin(double x)
double cos(double x)
double tan(double x)
double asin(double x)  
double acos(double x)  
double atan(double x)  
double floor(double x) x
double ceil(double x) x

1. C++

. , [8] [st; en] Step .

1. Microsoft Visio - (main) (F tabular_for) :

 
 

 

- Visio : File Stencil Flowchart Basic Flowchart Shapes.

2. BCW (Borland C++ for Windows) :

File New Project

 

"Project Path and Name" ( ide); "Platform" DOS (Standart);

, BGI Libraries;

OK, cpp -:

 


:

 
 

 

 


:

# include <iostream.h> // cin, cout

# include <iomanip.h> // setprecision, setw

# include <conio.h> // clrscr(), getch()

# include <math.h> // sin(x)

# include <graphics.h>

# include <stdlib.h> // exit

// :

Float F(float x);





:


: 2017-02-25; !; : 562 |


:

:

.
==> ...

1790 - | 1600 -


© 2015-2024 lektsii.org - -

: 0.016 .