integer
whole number in mathematics
A whole number without any decimal or fraction, like −2, 0, 5, or 100.
an integer between [number] and [number]
- Zero is an integer, even though it is neither positive nor negative.
- The function only accepts an integer as its input parameter.
- Write an example of an integer that is greater than 10 but less than 20.
- The teacher asked us to list all the integers between −5 and 5.
- In this exercise, you must round the result to the nearest integer.
- Five is an integer.
- Minus three is an integer.
- This program needs an integer, not a decimal number.
- Please choose an integer from one to ten.
- Zero is also an integer.
whole-number data type in computing
In computer programs, a kind of value that can store whole numbers only, not decimals.
an integer variable that stores [number]
- Use an integer variable to count the number of users who log in.
- In this database, the user ID is stored as an integer.
- Because of integer overflow, the result wrapped around to a negative value.
- You should convert the input text to an integer before doing any calculations.
- The function returns an integer representing the status code.
- This code uses an integer to store the age.
- Please change this field from text to integer.
- The program crashes when the integer is too large.
- We save the score as an integer in the game.
- The function takes two integers and adds them.
- Base: integer
- Plural: integers
integer division
1division that discards the remainder
A kind of division in math or programming where you keep only the whole-number answer and throw away the remainder or decimal part.
- In this language, the operator performs integer division, not normal division.
- Integer division of 7 by 3 gives 2, with a remainder of 1.
integer overflow
1integer value goes beyond its range
A problem in a computer program when an integer becomes too big or too small to store, causing a wrong value or error.
- The bug was caused by integer overflow when the counter passed two billion.
- To avoid integer overflow, we switched to a 64-bit integer type.
integer part
1whole-number portion of a value
The whole-number part of a number, without the decimal or fraction.
- The integer part of 5.9 is 5.
- Separate the integer part from the decimal part before rounding.
integer programming
1optimization with integer-only variables
A type of math problem in operations research where some or all choices must be whole numbers, not fractions.
- They used integer programming to optimize the delivery routes.
- Integer programming problems are often harder to solve than linear ones.
signed integer
1integer that can be negative or positive
An integer type in a computer that can store both negative and positive whole numbers.
- Use a signed integer for temperatures, since they can be below zero.
- By default, this language treats the type as a signed integer.
unsigned integer
1integer that cannot be negative
An integer number or type that allows only zero and positive values, not negative ones.
- An unsigned integer is enough for counting the number of items.
- Array indices are usually stored as an unsigned integer.
- We changed the field to an unsigned integer to double the maximum value.
- The variable is defined as an unsigned integer to avoid negative results.
- This field expects an unsigned integer in the configuration file.