DEV Community

Discussion on: Datatypes in C Programming.

Collapse
 
pauljlucas profile image
Paul J. Lucas

The C standard does not specify the sizes of data types. It specifies only the minimum sizes in terms of bits. sizeof(char) is always 1 "sizeof units" (not necessarily bytes) by definition. Sizes of all other types are relative to that.

You mention float in addition to double, but don't mention either short or long. You also don't mention any of the unsigned versions. You don't mention that char may be either signed or unsigned.

There are many for format specifiers; see here.

Collapse
 
sujithvsuresh profile image
Sujith V S

Thanks for your valuable comment. In this post i only have mentioned the basic datatypes and format specifiers that is used commonly. More detailed posts will be released in the upcoming days.

Collapse
 
pauljlucas profile image
Paul J. Lucas

In general when writing a technical post, if you intentionally don't cover all the details, you should say it and whether more details are coming later.