how to get sum of two numbers in vb.net?

Answer Posted / sonia

Sub Main()
Dim x, y, sum As Integer
Console.WriteLine("Enter two numbers")
x = Console.ReadLine()
y = Console.ReadLine()
sum = x + y
Console.WriteLine("Sum = " & sum)
Console.ReadLine()
'& is used for concatenation
End Sub

Is This Answer Correct ?    75 Yes 19 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can you please explain the difference between dispose and finalize()?

504


What is the difference between vb 6 and vb.net?

642


What is redim keyword?

577


Explain enumerator?

524


Explain what observations between vb.net and vc#.net?

561






Name some of the features present in vb 2005?

574


What do you mean by Redim in VB.NET?

674


Explain clr?

568


What are the different types of a stream?

561


What is the size of .net object?

588


What is the use of internal keyword?

574


What are the difference between dispose(), close(), exit(), end()?

517


What are the features present in vb 2005?

571


Explain private assembly?

513


Name a feature which is common to all .net languages?

582