datatypes

Integer, string, boolean

Datatypes are categories that specify what kind of value a piece of data holds in programming—integer, string, boolean, floating-point number, and so on.

The datatype determines what operations can be performed: you can add integers but not concatenate them like strings.

Languages vary in how strictly they enforce datatypes.

Also spelled as two words: data types.

primitives

integer

Number lacking fractions

  • floatBuoyant object or vehicle
  • stringSlender fiber or character sequence
  • booleanTrue-or-false valued

char · double · byte · short · long · void · unsigned · signed · literal · null

structures

array

Ordered collection or display

  • treeWoody perennial plant
  • graphVisual data display
  • stackItems piled vertically

queue · set · map · tuple · record · union · struct · object · hashtable · collection

validation

overflow

Exceed capacity and spill

precision · coercion · sanitization · parsing · formatting · constraint · range · domain · nullable · NaN

typing

generics

Unbranded equivalent products

optional · any · variant

encoding

binary

Consisting of two parts

  • bytesUnits of digital storage
  • bitsSmall portions or pieces
  • encodingConverting data to format

decoding · serialization · marshalling · JSON · XML · CSV · base64 · UTF-8 · compression · checksum

Opposites
abstraction level

datatypesvalues

Principles held worthwhile

instances · data · literals · objects · variables

structure vs. chaos

datatypesraw input

Unprocessed incoming information

blobs · void

Family

datatype

Familiarity
Top 500,000
Profile
Used worldwide · Timeless · Abstract · Rated G