PracticeDev/study_cpp/cpp_primer_source_code/Chapter 5/plus_one.cpp

15 lines
345 B
C++

// plus_one.cpp -- the increment operator
#include <iostream>
int main()
{
using std::cout;
int a = 20;
int b = 20;
cout << "a = " << a << ": b = " << b << "\n";
cout << "a++ = " << a++ << ": ++b = " << ++b << "\n";
cout << "a = " << a << ": b = " << b << "\n";
// std::cin.get();
return 0;
}