alien_fx_fiend

Visual Basic Sum Of 2 (sample code)

Jun 28th, 2019
194
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. Public num1 As Integer
  2. Public num2 As Integer
  3. Public answer As Integer
  4. Sub Main()
  5. Console.WriteLine("Type a number and press Enter")
  6. num1 = Console.ReadLine()
  7. Console.WriteLine("Type another number to add to it and press Enter")
  8. num2 = Console.ReadLine()
  9. answer = num1 + num2
  10. Console.WriteLine("The answer is " & answer)
  11. Console.ReadLine()
  12. End Sub
Add Comment
Please, Sign In to add comment