Get Answers to all your Questions

header-bg qa

Write a program in the BASIC language to calculate all even numbers from 1 to 100.

Answers (1)

best_answer

Dim j As Integer 
k = 0 
    For i = 1 To 100 
        If i Mod 2 = 0 Then 
            k = k + i 
        End If 
    Next 
MsgBox (k) 

Posted by

Deependra Verma

View full answer