aliensbrain
  • Home
  • Study
  • Quizzes
  • 🎤AI Practicefree
  • Notebooks
  • Community
  • Sign in
  • Software and Programming Basics
  • In C programming, what does I equal at the end of the fol...
Multiple choice

In C programming, what does I equal at the end of the following piece (snippet) of code? i =1;
i *=5; i +=3;

  1. 3

  2. 5

  3. 8

  4. 1

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

Starting with i=1, the operation i*=5 results in i=5. Then, i+=3 results in i=8.

Keep practicing — related questions

  • What would be the output of the following C code? int i=1, j=1; int n = 1; if(n>0){i++;j--;}printf(i=%d, j=...
  • What is the output?int i = 3;if (!i) i++; i++;if (i==3) i+=2; i+=2;printf("%d\n", i);
  • What will be the value of i? int i = 1; i = i +2*i ++; printf(“%d”,i);
  • What is the output of the following piece of code? int x = 3, y = 5, z; z = x + ++y; printf(“%d”,z);
  • i=3; Printf("%d%d%d",i++,++i,i); What will be output of the code snippet?
  • int a=10,b; b=a++ + ++a; printf(%d,%d,%d,%d,b,a++,a,++a); What will be the output when following code is ex...
  • What would be the output of the following statement in 'C'? int i=0; do { i=i+3; printf(n i=%d,i); }while(i...
  • The statement i++; is equivalent to
Play the full quiz 🎤 Practise this topic out loud
Advertisement
© Aliensbrain | all rights reserved
  • About
  • Contact
  • Terms and Condition
  • Privacy Policy