Advertisement
laith-0093

C++

Jan 16th, 2020
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. #include <iostream.h>
  2. #include <conio.h>
  3. void main ()
  4. {
  5. float L, M;
  6. char ch;
  7. do
  8. {
  9. cout << "\nEnter L: ";
  10. cin >> L;
  11. cout << "Enter M: ";
  12. cin >> M;
  13. cout << "\nL+M= " << L+M;
  14. cout << "\nL-M= " << L-M;
  15. cout << "\nL*M= " << L*M;
  16. if (M != 0)
  17. cout << "\nL/M= " << L/M;
  18. cout << " \n Do Again (y/n): ";
  19. cin >> ch;
  20. }
  21. while (ch != 'n');
  22. getch ();
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement