From ba11ff267aa0340fc2c3035a22b38239fd3f6c49 Mon Sep 17 00:00:00 2001 From: Daniel Date: Tue, 11 Dec 2018 03:23:35 -0500 Subject: [PATCH] Corrected minimum int value in intro of "Data Types in C" in the C Guide (#24692) * Corrected minimum int value in intro As described in the "Standard Integers" section, at minimum and int can store values -32,768 to 32,767. The negative value was incorrectly listed as -32,767 in the "Data Types in C" section. * fix: typo --- guide/english/c/data-types/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guide/english/c/data-types/index.md b/guide/english/c/data-types/index.md index 8065d1e060..f472727882 100644 --- a/guide/english/c/data-types/index.md +++ b/guide/english/c/data-types/index.md @@ -4,7 +4,7 @@ title: Data Types in C # Data Types in C There are several different ways to store data in C, and they are all unique from each other. The types of data that information can be stored as are called data types. C is much less forgiving about data types than other languages. As a result, it's important to make sure that you understand the existing data types, their abilities, and their limitations. -One quirk of C's data types is that they depend entirely on the hardware that you're running your code on. An `int` on your laptop will be smaller than an `int` on a supercomputer, so knowing the limitations of the hardware you're working on is important. This is also why the data types are defined as being minimums- an `int` value, as you will learn, is at minimum -32767 to 32767: on certain machines, it will be able to store even more values than this. +One quirk of C's data types is that they depend entirely on the hardware that you're running your code on. An `int` on your laptop will be smaller than an `int` on a supercomputer, so knowing the limitations of the hardware you're working on is important. This is also why the data types are defined as being minimums- an `int` value, as you will learn, is at minimum -32768 to 32767: on certain machines, it will be able to store even more values than this. There are two categories that we can break this into: integers, and floating point numbers. Integers are whole numbers. They can be positive, negative, or zero. Numbers like -321, 497, 19345, and -976812 are all perfectly valid integers, but 4.5 is not because 4.5 is not a whole number.