Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- setlocale(LC_ALL,"russian");
- float a,b;
- cout << "Введите два числа: ";
- cin >> a >> b;
- cout << "Сумма: " << a+b << endl;
- cout << "Разность: " << a-b << endl;
- cout << "Произведение: " << a*b << endl;
- if (b!=0) {
- cout << "Частное: " << a/b << endl;
- }
- else {
- cout << "На ноль делить нельзя" << endl;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement