21st century classroom
Dont be afraid of being diffrent be afraid of being the same as evry one else..๐ ๐๐๐๐
Wednesday, 19 September 2018
QBASIC program to display sum of even digits .
CLS
INPUT "Enter any number ";N
S = 0
WHILE N < > 0
R = N MOD 10
IF R MOD 2 = 0 THEN S = S + R
N = N \ 10
WEND
PRINT " Sum of even digits = " ; S
END
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment