Computer Science, asked by shaikhtazin, 5 months ago

write a simple loop program to accept an integer n and display all even numbers upto n​

Answers

Answered by SnowyPríncess
2

Answer:

How do you print even numbers in a for loop?

Step by step descriptive logic to print all even number between 1 to n using if condition.

Input upper limit to the even numbers from user. Store it in some variable say N .

Run a loop from 1 , that runs till N , increment the loop counter by 1 in each iteration. ...

Inside the loop body check even/odd condition.

Similar questions