[go: up one dir, main page]

0% found this document useful (0 votes)
34 views1 page

For Loop

This document contains 20 questions about using for loops in programming. The questions cover topics such as printing ranges of numbers, calculating sums and products of numbers, printing numbers in reverse order, taking user input, and analyzing sets of input numbers to find minimum, maximum, and average values. The goal is to write programs using for loops to solve each problem.

Uploaded by

Gagan Saini
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views1 page

For Loop

This document contains 20 questions about using for loops in programming. The questions cover topics such as printing ranges of numbers, calculating sums and products of numbers, printing numbers in reverse order, taking user input, and analyzing sets of input numbers to find minimum, maximum, and average values. The goal is to write programs using for loops to solve each problem.

Uploaded by

Gagan Saini
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 1

FOR LOOP (PART 1)

QUESTION 1: WAP TO PRINT ALL THE NUMBERS FROM A TO B. QUESTION 2: WAP TO PRINT ALL THE EVEN NUMBERS FROM A TO B. QUESTION 3: WAP TO PRINT ALL THE ODD NUMBERS FROM A TO B. QUESTION 4: WAP TO PRINT THE SUM OF ALL THE NUMBERS FROM 1 TO 10. QUESTION 5: WAP TO PRINT THE SUM OF ALL THE NUMBERS FROM A TO B. QUESTION 6: WAP TO PRINT THE SUM OF ALL THE EVEN NUMBERS FROM A TO B. QUESTION 7: WAP TO PRINT THE PRODUCTS OF ALL THE NUMBERS FROM 1 TO 10. QUESTION 8: WAP TO PRINT THE PRODUCT OF ALL THE NUMBERS FROM A TO B. QUESTION 9: WAP TO PRINT ALL THE NUMBERS FROM 10-1.(I.E IN REVERSE ORDER). QUESTION 10: WAP TO PRINT THE PRODUCT OF ALL THE EVEN NUMBERS FROM A TO B. QUESTION 11: WAP TO PRINT THE TABLE OF 5. QUESTION 12: WAP TO PRINT THE TABLE OF ANY INPUTED NUMBER. QUESTION 13: WAP TO INPUT 20 NUMBERS AND PRINT THE NUMBER OF NUMBERS THAT ARE GREATER THAN 100. QUESTION 14: WAP TO INPUT 20 NUMBERS AND PRINT THE SUM OF NUMBERS WHICH ARE GREATER THAN 100. QUESTION 15: WAP TO PRINT THE SUM OF TABLE OF 5. QUESTION 16: WAP TO PRINT THE SUM OF TABLE OF N. QUESTION 17: WAP TO PRINT THE PRODUCT OF ALL THE NUMBERS FROM 1 TO N.(THIS IS ALSO KNOWN AS FACTORIAL OF A NUMBER. EX: FACTORIAL OF 5=5*4*3*2*1;). QUESTION 18: WAP TO INPUT 1000 NUMBERS AND PRINT THE SMALLEST NUMBER. QUESTION 19: WAP TO INPUT 1000 NUMBERS AND PRINT THE BIGGEST NUMBER. QUESTION 20: WAP TO INPUT 1000 NUMBERS AND PRINT THE SMALLEST NUMBER.

You might also like