QB64.com

QB64 is a modern extended BASIC programming language that retains QBasic/QuickBASIC 4.5 compatibility and compiles native binaries for Windows, Linux, and macOS.

_DEFINE defines a set of variable names according to their first character as a specified data type.

Syntax

_DEFINE letter[-range, …] AS [_UNSIGNED] dataVariable Types

Parameter(s)

Description

Example(s)

Defining variables that start with the letters A, B, C or F as unsigned integers, including the Add2 FUNCTION.


_DEFINE A-C, F AS _UNSIGNED INTEGER

PRINT Add2(-1.1, -2.2)

END

FUNCTION Add2 (one, two)
Add2 = one + two
END FUNCTION 


65533

Explanation: Unsigned integers can only return positive values while ordinary INTEGER can also return negative values.

See Also