C
Programming and Technical
Programming
integer i = 0
integer sum = 0
while ( i <= 50 )
{
sum = sum + i
-- MISSING STATEMENT 5 --
}
print sum
Read Solution (Total 6)
-
- i++ -To increment the variable otherwise it will run ifinite times
- 6 years agoHelpfull: Yes(1) No(0)
- /*Why not u run this*/
#include
int main()
{
int i = 0;
int sum = 0;
while ( i - 6 years agoHelpfull: Yes(1) No(1)
- infinite loop is the answer because the value of i is not updating...
- 6 years agoHelpfull: Yes(0) No(0)
- Increment statement
i++ - 6 years agoHelpfull: Yes(0) No(0)
- i++;
in order to increment the i vaue we should use i++ otherwise the loop will execute infinite time - 6 years agoHelpfull: Yes(0) No(0)
- i++;
//incrimenting - 6 years agoHelpfull: Yes(0) No(0)
C Other Question