// Code derived from Stroustrup's PPP2 book// § 6.3.1 First attempt// -and beginning on p 179#include<iostream>usingstd::cin;usingstd::cout;intmain(){cout<<"Please enter expression (we can handle + and –): \n";intlval=0;intrval=0;charop=' ';intres=0;cin>>lval>>op>>rval;// read something like 1 + 3if(op=='+')res=lval+rval;// additionelseif(op=='-')res=lval-rval;// subtractioncout<<"Result: "<<res<<'\n';}