First you need to create a new project by select File -> New project
Enter your project name, then click OK button to complete
Module Module1
Sub Main()
Console.WriteLine("Hello, world!")
Console.ReadLine()
End Sub
End Module
Now, we'll add a "Hello, world!" string to your main program. The main thread will begin when your program start, to display results on your screen we use WriteLine method, to Read value from keyboard you can use ReadLine method.
Now, press F5 to run your program.
Now change the title of this window or text color
Module Module1
Sub Main()
Console.Title = "c-sharpcode.com"
Console.ForegroundColor = ConsoleColor.Yellow
Console.WriteLine("Hello, world!")
Console.ReadLine()
End Sub
End Module
Now, press F5 to run your program, you will see:
Now i give you sample code:
Module Module1
Sub Main()
Console.WriteLine(" 1 + 9 = ? ")
If Console.ReadLine() = "10" Then
Console.WriteLine(" it is true")
Else
Console.WriteLine(" it is false")
End If
Console.ReadLine()
End Sub
End Module
you will see:
Enjoy!!! by Aziz Lazreg.