Biology Forums - Study Force

Science-Related Homework Help Computer Studies Topic started by: Heff on Sep 3, 2017



Title: What is the value of donuts after the following code executes?int donuts = 10;if (donuts = 1) ...
Post by: Heff on Sep 3, 2017
What is the value of donuts after the following code executes?

   int donuts = 10;
   
   if (donuts = 1)
       donuts = 0;
   else
       donuts += 2;

A) 0
B) 10
C) 12
D) 1


Title: Re: What is the value of donuts after the following code executes?int donuts = 10;if (donuts = 1) ...
Post by: bestavinash on Sep 3, 2017
Content hidden