Effects of prefix and postfix notation : Prefix postfix « Language « C++






Effects of prefix and postfix notation

Effects of prefix and postfix notation

#include <iostream>
using namespace std;
int main()
{
   int i(12), j(18);
   cout << i++ << endl;
   cout << i++ << endl;
   cout << i   << endl;       
   cout << j-- << endl;       
   cout << --j << endl;
   cout << --j << endl;
   return 0;
} 

           
       








Related examples in the same category

1.Example of using the postfix and prefixExample of using the postfix and prefix