There are two type for finding Odd & Even Numbers
There are two type for finding Odd & Even Numbers
Rate There are two type for finding Odd & Even Numbers
(1(1 Vote))
'Create one project called OddEven & write down this code in Command1 Click Event
Private Sub Command1_Click()
if Val(Text1) Mod 2 = 0 then
Msgbox "Even"
else
Msgbox "Odd"
End if
' OR Second Method is
if val(Text1.Text) / 2= Round(val(Text1.Text) / 2,0) then
Msgbox "Even"
else
Msgbox "Odd"
End if
End Sub
'Hi there send me reply how you like this code @ [email protected]
There are two type for finding Odd & Even Numbers Comments
No comments yet — be the first to post one!
Post a Comment