The following code has errors . Rewrite the correct code underlining all the corrections made :
Integer counter =0;
For (num =1; num>=1 ; num--):
{
If i%num =0
counter = counter + 1 ;
}
Answers
Answered by
0
int counter =0;
`````
int i=2;
`````````````
for(int num=1;num<=100;num++)
{ ````` `````````````````````````````````
if(num%i==0)
{ ```````````````````````
counter=counter+1;
}
}
``
`````
int i=2;
`````````````
for(int num=1;num<=100;num++)
{ ````` `````````````````````````````````
if(num%i==0)
{ ```````````````````````
counter=counter+1;
}
}
``
Similar questions
Social Sciences,
7 months ago
Math,
7 months ago
Environmental Sciences,
7 months ago
Physics,
1 year ago
Political Science,
1 year ago
Math,
1 year ago
Math,
1 year ago