49. Write a program in java to find the sum of all natural numbers from 1 to 100.(Java, Python, JavaScript, QBasic, C, Go, c++, C#, R)

Algorithm :

Step 1: Start

Step 2: For I = 1 To 100

If True GoTo Step 3

Else GoTo Step 4

Step 3: S = S + I

GoTo Step 2

Step 4: Print “ Sum of All Natural Number from 1 to 100 “ S

Step 5: Stop/End

Flowchart:

Create a flowchart to find the sum of all natural numbers from 1 to 100.
Create a flowchart to find the sum of all natural numbers from 1 to 100.
Total
0
Shares
Leave a Reply

Your email address will not be published. Required fields are marked *

Previous Post

48. Write a program in java using Sub procedure to print 1, 10, 101, 1010, 10101.(Java, Python, JavaScript, QBasic, C, Go, c++, C#, R)

Next Post

Traffic Signs Recognition By Shiv Kumar Yadav

Related Posts