Thursday, 27 April 2017

Compare B/W Two Values by VB Script

Program

a=cint(inputbox ("enter the value of a"))
b=cint(inputbox("enter the value of b"))

if (a>b) then
msgbox "a is greater than b"

elseif (a<b) then
msgbox "a is smaller than b"

else
msgbox "a and b are same"

end if

Steps-
Step1-Open Notepad and write the program.
Step2- Save as this file- .vbs
Step3- open file and get output

No comments:

Post a comment

Note: only a member of this blog may post a comment.