Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
PureBasic
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Data types === Variable data type specified when you first use it (and optionally - in the future), and is separated from the name of the point. There is a set of basic types - {{mono|.f, .d}} (float and double numbers), {{mono|.b, .c, .w, .l, .q}} (integers - from single-byte and 8-byte), {{mono|.s}} - strings. {| class="wikitable" |- ! Type !! Suffix !! Memory usage !! Numerical range |- | Byte || {{mono|b}} || 1 byte (8 bits) || β128 ... +127 |- | Ascii || {{mono|a}} || 1 byte (8 bits) || 0 ... +255 |- | Character || {{mono|c}} || 1 byte (8 bits) (ascii) || 0 ... +255 |- | Word || {{mono|w}} || 2 bytes (16 bits) || β32768 ... +32767 |- | Unicode || {{mono|u}} || 2 bytes (16 bits) || 0 ... +65535 |- | Character || {{mono|c}} || 2 bytes (16 bits) (unicode) || 0 ... +65535 |- | Long || {{mono|l}} || 4 bytes (32 bits) || β2147483648 ... +2147483647 |- | Integer || {{mono|i}} || 4 bytes (32 bits) x86 || β2147483648 ... +2147483647 |- | Float || {{mono|f}} || 4 bytes (32 bits) || Depending on the ratio of the decimal number. |- | Integer || {{mono|i}} || 8 bytes (64 bits) x64 || β9223372036854775808 ... +9223372036854775807 |- | Quad || {{mono|q}} || 8 bytes (64 bits) || β9223372036854775808 ... +9223372036854775807 |- | Double || {{mono|d}} || 8 bytes (64 bits) || Depending on the ratio of the decimal number. |- | String || {{mono|s}} || (String length + 1) * [[sizeof|SizeOf]](Character) || No limit. |- | Fixed String || {{mono|s{length}}} || (String length) * SizeOf(Character) || No limit. |} * {{mono|Len(String)}} used to count the length of a string will not exceed the first [[null character]] ({{mono|Chr(0)}}). In addition to basic types, the user can define the type of construction via <syntaxhighlight lang="text"> Structure type_name field_name.type ; Single field. Perhaps the structures attachment. field_name[count].type ; Static arrays. ; ... ; Optional construction StructureUnion .. EndStructureUnion allows you ; to combine multiple fields into one area of memory ; that is sometimes required for the conversion types. StructureUnion type_name.type ; ... EndStructureUnion EndStructure </syntaxhighlight> Variables can be single (actually, standard variables), [[dynamic array]] (declared using the {{code|lang=blitzbasic|Dim var_name.type_name (size1, size2, ... )}}, a [[linked list]] ({{code|lang=blitzbasic|List() var_name.type_name}}), an [[associative array]] (in new versions of language) ({{code|Map var_name.type_name()}})
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
PureBasic
(section)
Add topic