Académique Documents
Professionnel Documents
Culture Documents
#include <iostream>
#include <iomanip>
int x , y ;
void affiche () ;
};
x= abs ;
y= ord ;
x+=dx;
y+=dy;
cout<< "Je suis en " << x << " " << y << "\n" ;
/* run this program using the console pauser or add your own getch, system("pause") or input loop
*/
p1.affiche();
return 0;
Les classe :
#include <iostream>
#include <iomanip>
class point {
private :
int x ;
int y ;
public :
int Getx();
y=b;
};
x=abs;
y=ord;
x=x+dx;
y=y+dy;
}
int point::Getx(){
return x;
x=v;
void point::affiche(){
cout << "Je suis en " << x << " " << y << "\n" ;
main (){
point a, b ;
b.Set(8);
cout<<a.Getx();