2 2 votes Size of $\verb|int|$ is $\mathrm{2~B}$ and size of $\verb|float|$ is $\mathrm{4~B}$Consider the following C++ program:#include<iostream> using namespace std; int main() { int a = 4; float b = 3; cout << sizeof(++a + b) << " "; cout << a; return 0; }What will be the output produced by the above program?$4~5$ $4~4$ $6~5$ $4~6$ BARC barc2026-cs-memorybased goclasses programming three-marks + – GO Classes 353 views answer comment Share Follow Print 0 reply Please log in or register to add a comment.
0 0 votes Key concept : 1. sizeof does not evaluate the expression inside it .2. It only check the type of expression at comile time.3. so ++a is not executed step 1 ++a + b a = int b = float int + float = float ;sizeof(float) = 4 ++a. is not executed so value of a remain same . so final ouptuput = 4 4 so option B is correct. akash_kumar 9 answered Mar 17 akash_kumar 9 comment Share Follow 0 reply Please log in or register to add a comment.