Hello World 2
The program demonstrates using the Declare statement and defining a function.
'Hello World 2
'This example demostrates using a Declare statement
'and function definition
'**********************************************
Declare Function GetHello() as String
'Create a string variable
Dim HelloString as String
'Clear the screen
Cls
'Get the hello string
HelloString = GetHello
'Print to console window
Print HelloString
'Wait for keypress
Sleep
'End program
End
'GetHello function: Returns a string to caller
Function GetHello() as String
Return "Hello World from FreeBasic!"
End Function





