Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "stdafx.h"
- #include "iostream"
- #include "math.h"
- #include "conio.h"
- using namespace std;
- int _tmain(int argc, _TCHAR* argv[])
- {
- double x1,x2,y1,y2,a,b;
- cout << "Enter a:"; cin >> a;
- cout << "Enter b:"; cin >> b;
- cout << "A(x1,y1) x1:"; cin >> x1;
- cout << " y1:"; cin >> y1;
- if (y1==a*x1+b) cout << "A prinadlezhit";
- else cout << "A ne prinadlezhit";
- _getch();
- cout << "B(x2,y2) x2:"; cin >> x2;
- cout << " y2:"; cin >> y2;
- if (y2==a*x2+b) cout << "B prinadlezhit";
- else cout << "B ne prinadlezhit";
- _getch();
- return 0;
- }
Add Comment
Please, Sign In to add comment