Difference between revisions of "DEFINE"

From QB64 Wiki
Jump to navigation Jump to search
imported>Clippy
m
imported>Clippy
m
Line 16: Line 16:
  
  
''Explanation:'' Variables that starts with A, B, C or F will now be defined as a unsigned integer, unsigned integers can only take positive values, ordinary integers can also take negative values.
+
''Explanation:'' Variables that start with the letters A, B, C or F will now be defined as a unsigned integers. Unsigned integers can only take positive values and ordinary integers can also take negative values.
  
  
Line 23: Line 23:
  
 
''See also:'' [[DEFSTR]], [[DEFLNG]], [[DEFINT]], [[DEFSNG]], [[DEFDBL]], [[_UNSIGNED]], [[ABS]], [[SGN]]
 
''See also:'' [[DEFSTR]], [[DEFLNG]], [[DEFINT]], [[DEFSNG]], [[DEFDBL]], [[_UNSIGNED]], [[ABS]], [[SGN]]
 +
 +
''Referance:'' [[Mathematical Operations]]
 +
  
  

Revision as of 23:48, 28 September 2009

_DEFINE lets you define a range of variables according to their first character as a datatype.


Syntax: _DEFINE range or letter[, range2 or letter2[, range3 or letter3[, ...]]] AS datatype




Example: _DEFINE A-C, F AS UNSIGNED INTEGER


Explanation: Variables that start with the letters A, B, C or F will now be defined as a unsigned integers. Unsigned integers can only take positive values and ordinary integers can also take negative values.



See also: DEFSTR, DEFLNG, DEFINT, DEFSNG, DEFDBL, _UNSIGNED, ABS, SGN

Referance: Mathematical Operations



Navigation:

Go to Keyword Reference - Alphabetical

Go to Keyword Reference - By usage