Maestro1

ООП_ЛР1

Mar 6th, 2024
742
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.25 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. int main()
  4. {
  5.     using namespace std;
  6.     char a='a', b = 'b', dop_per;
  7.    
  8.     char *a1 = &a;
  9.     char *b1 = &b;
  10.  
  11.     dop_per = *a1;
  12.     a = *b1;
  13.     b = dop_per;
  14.    
  15.     cout <<"a="<<a<<"\nb="<<b<<endl;
  16.     return 0;
  17. }
Advertisement
Add Comment
Please, Sign In to add comment