🕷️ Crawler Inspector

URL Lookup

Direct Parameter Lookup

Raw Queries and Responses

1. Shard Calculation

Query:
Response:
Calculated Shard: 152 (from laksa082)

2. Crawled Status Check

Query:
Response:

3. Robots.txt Check

Query:
Response:

4. Spam/Ban Check

Query:
Response:

5. Seen Status Check

ℹ️ Skipped - page is already crawled

📄
INDEXABLE
✅
CRAWLED
6 days ago
🤖
ROBOTS ALLOWED

Page Info Filters

FilterStatusConditionDetails
HTTP statusPASSdownload_http_code = 200HTTP 200
Age cutoffPASSdownload_stamp > now() - 6 MONTH0.2 months ago (distributed domain, exempt)
History dropPASSisNull(history_drop_reason)No drop reason
Spam/banPASSfh_dont_index != 1 AND ml_spam_score = 0ml_spam_score=0
CanonicalPASSmeta_canonical IS NULL OR = '' OR = src_unparsedNot set

Page Details

PropertyValue
URLhttps://en.wikipedia.org/wiki/C_(programming_language)
Last Crawled2026-03-31 14:33:51 (6 days ago)
First Indexed2013-08-08 16:38:14 (12 years ago)
HTTP Status Code200
Meta TitleC (programming language) - Wikipedia
Meta Descriptionnull
Meta Canonicalnull
Boilerpipe Text
"C lang" redirects here. For the compiler front end, see Clang . Not to be confused with C++ or C# . C Logotype used on the cover of the first edition of The C Programming Language [ 1 ] Paradigm Multi-paradigm : imperative ( procedural ), structured Designed by Dennis Ritchie Developer ANSI X3J11 ( ANSI C ); ISO/IEC JTC 1 (Joint Technical Committee 1) / SC 22 (Subcommittee 22) / WG 14 (Working Group 14) (ISO C) First appeared 1972 ; 54 years ago [ a ] Stable release C23 / October 31, 2024 ; 17 months ago Preview release C2Y (N3220) / February 21, 2024 ; 2 years ago [ 5 ] Typing discipline Static , weak , manifest , nominal OS Cross-platform Filename extensions .c, .h Website c-language.org iso.org open-std.org Major implementations pcc , GCC , Clang , Intel C , C++Builder , Microsoft Visual C++ , Watcom C Dialects Cyclone , Unified Parallel C , Split-C , Cilk , C* Influenced by B , BCPL , CPL , ALGOL 68 , [ b ] PL/I , Fortran Influenced Numerous : AMPL , AWK , csh , C++ , C-- , C# , Objective-C , D , Go , Java , JavaScript , JS++ , Julia , Limbo , LPC , Perl , PHP , Pike , Processing , Python , Rust , V (Vlang) , Vala , Verilog (HDL), [ 8 ] Nim , Zig C Programming at Wikibooks C [ c ] is a general-purpose programming language created in the 1970s by Dennis Ritchie . By design, C gives the programmer relatively direct access to the features of the typical CPU architecture, customized for the target instruction set . It has been and continues to be used to implement operating systems (especially kernels [ 10 ] ), device drivers , and protocol stacks , but its use in application software has been decreasing. [ 11 ] C is used on computers that range from the largest supercomputers to the smallest microcontrollers and embedded systems . A successor to the programming language B , C was originally developed at Bell Labs by Ritchie between 1972 and 1973 to construct utilities running on Unix . It was applied to re-implementing the kernel of the Unix operating system. [ 12 ] During the 1980s, C gradually gained popularity. It has become one of the most widely used programming languages , [ 13 ] [ 14 ] with C compilers available for practically all modern computer architectures and operating systems . The book The C Programming Language , co-authored by the original language designer, served for many years as the de facto standard for the language. [ 15 ] [ 1 ] C has been standardized since 1989 by the American National Standards Institute (ANSI) and, subsequently, jointly by the International Organization for Standardization (ISO) and the International Electrotechnical Commission (IEC). C is an imperative procedural language, supporting structured programming , lexical variable scope , and recursion , with a static type system . It was designed to be compiled to provide low-level access to memory and language constructs that map efficiently to machine instructions , all with minimal runtime support . Despite its low-level capabilities, the language was designed to encourage cross-platform programming. A standards -compliant C program written with portability in mind can be compiled for a wide variety of computer platforms and operating systems with few changes to its source code. Although neither C nor its standard library provide some popular features found in other languages, it is flexible enough to support them. For example, object orientation and garbage collection are provided by external libraries GLib Object System and Boehm garbage collector , respectively. Since 2000, C has typically ranked as the most or second-most popular language in the TIOBE index . [ 16 ] Dennis Ritchie (right), the inventor of the C programming language, with Ken Thompson The C language exhibits the following characteristics: Free-form source code Semicolons terminate statements Curly braces group statements into blocks Executable code is contained in functions (no script-like syntax) Parameters are passed by value; pass by-reference is achieved by passing a pointer to a value Relatively small number of keywords Control flow constructs, including if , for , do , while , and switch Arithmetic , bitwise , and logic operators, including + , += , ++ , & , || Multiple assignments may be performed in a single statement User-defined identifiers are not distinguished from keywords (i.e., by a sigil ) A variable declared inside a block is accessible only in that block and only below the declaration A function return value can be ignored A function cannot be nested inside a function, but some translators support this Run-time polymorphism may be achieved using function pointers Supports recursion Data typing is static , but weakly enforced ; all variables have a type, but implicit conversion between primitive types weakens the separation of the different types User-defined data types allow for aliasing a data type specifier Syntax for array definition and access is via square bracket notation, for example month[11] . Indexing is defined in terms of pointer arithmetic. Whole arrays cannot be copied or compared without custom or library code User-defined structure types allow related data elements to be passed and copied as a unit although two structures cannot be compared without custom code to compare each field User-defined union types support overlapping members, allowing multiple data types to share the same memory location User-defined enumeration types support aliasing integer values Lacks a string type but has syntax for null-terminated strings with associated handling in its standard library Supports low-level access to computer memory via pointers Supports procedure-like construct as a function returning void Supports dynamic memory via standard library functions Includes the C preprocessor to perform macro definition, source code file inclusion, and conditional compilation Supports modularity in that files are processed separately, with visibility control via static and extern attributes Minimized functionality in the core language while relatively complex functionality such as I/O , string manipulation, and mathematical functions supported via standard library functions Resulting compiled code has relatively straightforward needs on the underlying platform, making it desirable for operating and embedded systems "Hello, world" example [ edit ] "Hello, World!" program by Brian Kernighan (1978) The "Hello, World!" program example that appeared in the first edition of K&R has become the model for an introductory program in most programming textbooks. The program prints "hello, world" to the standard output . The original version was: [ 17 ] main () { printf ( "hello, world \n " ); } A more modern version is: [ d ] #include <stdio.h> int main ( void ) { printf ( "hello, world \n " ); } The first line is a preprocessor directive , indicated by #include , which causes the preprocessor to replace that line of code with the text of the stdio.h header file, which contains declarations for input and output functions including printf . The angle brackets around stdio.h indicate that the header file can be located using a search strategy that selects header files provided with the compiler over files with the same name that may be found in project-specific directories. The next code line declares the entry point function main . The run-time environment calls this function to begin program execution. The type specifier int indicates that the function returns an integer value. The void parameter list indicates that the function consumes no arguments. The run-time environment actually passes two arguments (typed int and char *[] ), but this implementation ignores them. The ISO C standard (section 5.1.2.2.1) requires syntax that either is void or these two arguments – a special treatment not afforded to other functions. The opening curly brace indicates the beginning of the code that defines the function. The next line of code calls (diverts execution to) the C standard library function printf with the address of the first character of a null-terminated string specified as a string literal . The text \n is an escape sequence that denotes the newline character which when output in a terminal results in moving the cursor to the beginning of the next line. Even though printf returns an int value, it is silently discarded. The semicolon ; terminates the call statement. The closing curly brace indicates the end of the main function. Prior to C99, an explicit return 0; statement was required at the end of main function, but since C99, the main function (as being the initial function call) implicitly returns 0 upon reaching its final closing curly brace. [ e ] Timeline of C language Year Informal name Official standard 1972 first release N/a 1978 K&R C N/a 1989, 1990 ANSI C , C89, ISO C, C90 ANSI X3.159-1989 ISO/IEC 9899:1990 1999 C99 , C9X ISO/IEC 9899:1999 2011 C11 , C1X ISO/IEC 9899:2011 2018 C17 , C18 ISO/IEC 9899:2018 2024 C23 , C2X ISO/IEC 9899:2024 TBA C2Y The origin of C is closely tied to the development of the Unix operating system, originally implemented in assembly language on a PDP-7 by Dennis Ritchie and Ken Thompson , incorporating several ideas from colleagues. Eventually, they decided to port the operating system to a PDP-11 . The original PDP-11 version of Unix was also developed in assembly language. [ 12 ] Thompson wanted a programming language for developing utilities for the new platform. He first tried writing a Fortran compiler, but he soon gave up the idea and instead created a cut-down version of the recently developed systems programming language called BCPL . The official description of BCPL was not available at the time, [ 19 ] and Thompson modified the syntax to be less 'wordy' and similar to a simplified ALGOL known as SMALGOL. [ 20 ] He called the result B , [ 12 ] describing it as "BCPL semantics with a lot of SMALGOL syntax". [ 20 ] Like BCPL, B had a bootstrapping compiler to facilitate porting to new machines. [ 20 ] Ultimately, few utilities were written in B because it was too slow and could not take advantage of PDP-11 features such as byte addressability. Unlike BCPL's // comment marking comments up to the end of the line, B adopted /* comment */ as the comment delimiter, more akin to PL/1, and allowing comments to appear in the middle of lines. (BCPL's comment style would be reintroduced in C++.) [ 12 ] New B and first C release [ edit ] In 1971 Ritchie started to improve B, to use the features of the more-powerful PDP-11. A significant addition was a character data type. He called this New B (NB). [ 20 ] Thompson started to use NB to write the Unix kernel, and his requirements shaped the direction of the language development. [ 20 ] [ 21 ] Through to 1972, richer types were added to the NB language. NB had arrays of int and char , and to these types were added pointers, the ability to generate pointers to other types, arrays of all types, and types to be returned from functions. Arrays within expressions were effectively treated as pointers. A new compiler was written, and the language was renamed C. [ 12 ] The C compiler and some utilities made with it were included in Version 2 Unix , which is also known as Research Unix . [ 22 ] Structures and Unix kernel re-write [ edit ] At Version 4 Unix , released in November 1973, the Unix kernel was extensively re-implemented in C. [ 12 ] By this time, the C language had acquired some powerful features such as struct types. The preprocessor was introduced around 1973 at the urging of Alan Snyder and also in recognition of the usefulness of the file-inclusion mechanisms available in BCPL and PL/I . Its original version provided only included files and simple string replacements: #include and #define of parameterless macros. Soon after that, it was extended, mostly by Mike Lesk and then by John Reiser, to incorporate macros with arguments and conditional compilation . [ 12 ] Unix was one of the first operating system kernels implemented in a language other than assembly . Earlier instances include the Multics system (which was written in PL/I ) and Master Control Program (MCP) for the Burroughs B5000 (which was written in ALGOL ) in 1961. In and around 1977, Ritchie and Stephen C. Johnson made further changes to the language to facilitate portability of the Unix operating system. Johnson's Portable C Compiler served as the basis for several implementations of C on new platforms. [ 21 ] The cover of the book The C Programming Language , first edition, by Brian Kernighan and Dennis Ritchie In 1978 Brian Kernighan and Dennis Ritchie published the first edition of The C Programming Language . [ 23 ] Known as K&R from the initials of its authors, the book served for many years as an informal specification of the language. The version of C that it describes is commonly referred to as " K&R C ". As this was released in 1978, it is now also referred to as C78 . [ 24 ] The second edition of the book [ 25 ] covers the later ANSI C standard, described below. K&R introduced several language features: Standard I/O library long int data type unsigned int data type Compound assignment operators of the form = op (such as =- ) were changed to the form op = (that is, -= ) to remove the semantic ambiguity created by constructs such as i=-10 , which had been interpreted as i =- 10 (decrement i by 10) instead of the possibly intended i = -10 (let i be −10). Even after the publication of the 1989 ANSI standard, for many years K&R C was still considered the " lowest common denominator " to which C programmers restricted themselves when maximum portability was desired, since many older compilers were still in use, and because carefully written K&R C code can be legal Standard C as well. Although later versions of C require functions to have an explicit type declaration, K&R C only requires functions that return a type other than int to be declared before use. Functions used without prior declaration were presumed to return int . For example: long long_function (); calling_function () { long longvar ; register intvar ; longvar = long_function (); if ( longvar > 1 ) intvar = 0 ; else intvar = int_function (); return intvar ; } The declaration of long_function() (on line 1) is required since it returns long ; not int . Function int_function can be called (line 11) even though it is not declared since it returns int . Also, variable intvar does not need to be declared as type int since that is the default type for register keyword. Since function declarations did not include information about arguments, type checks were not performed, although some compilers would issue a warning if different calls to a function used different numbers or types of arguments. Tools such as Unix's lint utility were developed that (among other things) checked for consistency of function use across multiple source files. In the years following the publication of K&R C, several features were added to the language, supported by compilers from AT&T (in particular PCC [ 26 ] ) and other vendors. These included: void functions; functions returning no value Functions returning struct or union types Assignment for struct variables Enumerated types The popularity of the language, lack of agreement on standard library interfaces, and lack of compliance to the K&R specification, led to standardization efforts. [ 27 ] During the late 1970s and 1980s, versions of C were implemented for a wide variety of mainframe computers , minicomputers , and microcomputers , including the IBM PC , as its popularity increased significantly. In 1983 the American National Standards Institute (ANSI) formed a committee, X3J11, to establish a standard specification of C. X3J11 based the C standard on the Unix implementation; however, the non-portable portion of the Unix C library was handed off to the IEEE working group 1003 to become the basis for the 1988 POSIX standard. In 1989, the C standard was ratified as ANSI X3.159-1989 "Programming Language C". This version of the language is often referred to as ANSI C , Standard C, or sometimes C89 . In 1990 the ANSI C standard (with formatting changes) was adopted by the International Organization for Standardization (ISO) as ISO/IEC 9899:1990, which is sometimes called C90 . Therefore, the terms "C89" and "C90" refer to the same programming language. ANSI, like other national standards bodies, no longer develops the C standard independently, but defers to the international C standard, maintained by the working group ISO/IEC JTC1/SC22 /WG14. National adoption of an update to the international standard typically occurs within a year of ISO publication. One of the aims of the C standardization process was to produce a superset of K&R C, incorporating many of the subsequently introduced unofficial features. The standards committee also included several additional features such as function prototypes (borrowed from C++), void pointers, support for international character sets and locales , and preprocessor enhancements. Although the syntax for parameter declarations was augmented to include the style used in C++, the K&R interface continued to be permitted, for compatibility with existing source code. C89 is supported by current C compilers, and most modern C code is based on it. Any program written only in Standard C and without any hardware-dependent assumptions will run correctly on any platform with a conforming C implementation, within its resource limits. Without such precautions, programs may compile only on a certain platform or with a particular compiler, due, for example, to the use of non-standard libraries, such as GUI libraries, or to a reliance on compiler- or platform-specific attributes such as the exact size of data types and byte endianness . In cases where code must be compilable by either standard-conforming or K&R C-based compilers, the __STDC__ macro can be used to split the code into Standard and K&R sections to prevent the use on a K&R C-based compiler of features available only in Standard C. After the ANSI/ISO standardization process, the C language specification remained relatively static for several years. In 1995, Normative Amendment 1 to the 1990 C standard (ISO/IEC 9899/AMD1:1995, known informally as C95) was published, to correct some details and to add more extensive support for international character sets. [ 28 ] Main article: C99 The C standard was further revised in the late 1990s, leading to the publication of ISO/IEC 9899:1999 in 1999, which is commonly referred to as " C99 ". It has since been amended three times by Technical Corrigenda. [ 29 ] C99 introduced several new features, including inline functions , several new data types (including long long int and a complex type to represent complex numbers ), variable-length arrays and flexible array members , improved support for IEEE 754 floating point, support for variadic macros (macros of variable arity ), and support for one-line comments beginning with // , as in BCPL or C++. Many of these had already been implemented as extensions in several C compilers. C99 is for the most part backward compatible with C90, but is stricter in some ways; in particular, a declaration that lacks a type specifier no longer has int implicitly assumed. A standard macro __STDC_VERSION__ is defined with value 199901L to indicate that C99 support is available. GCC , Solaris Studio , and other C compilers now [ when? ] support many or all of the new features of C99. The C compiler in Microsoft Visual C++ , however, implements the C89 standard and those parts of C99 that are required for compatibility with C++11 . [ 30 ] [ needs update ] In addition, the C99 standard requires support for identifiers using Unicode in the form of escaped characters (e.g. \u0040 or \U0001f431 ) and suggests support for raw Unicode names. Main article: C11 Work began in 2007 on another revision of the C standard, informally called "C1X" until its official publication of ISO/IEC 9899:2011 on December 8, 2011. The C standards committee adopted guidelines to limit the adoption of new features that had not been tested by existing implementations. The C11 standard adds numerous new features to C and the library, including type generic macros, anonymous structures, improved Unicode support, atomic operations, multi-threading, and bounds-checked functions. It also makes some portions of the existing C99 library optional, and improves compatibility with C++. The standard macro __STDC_VERSION__ is defined as 201112L to indicate that C11 support is available. Main article: C17 C17 is an informal name for ISO/IEC 9899:2018, a standard for the C programming language published in June 2018. It introduces no new language features, only technical corrections, and clarifications to defects in C11. The standard macro __STDC_VERSION__ is defined as 201710L to indicate that C17 support is available. Main article: C23 C23 is an informal name for the current major C language standard revision. It was known as "C2X" through most of its development. It builds on past releases, introducing features like new keywords, additional meaning for auto to provide type inference when declaring variables, new types including nullptr_t and _BitInt(N) , and expansions to the standard library. [ 31 ] C23 was published in October 2024 as ISO/IEC 9899:2024. [ 32 ] The standard macro __STDC_VERSION__ is defined as 202311L to indicate that C23 support is available. Main article: C2Y C2Y is an informal name for the next major C language standard revision, after C23 (C2X), that is hoped to be released later in the 2020s, hence the '2' in "C2Y". An early working draft of C2Y was released in February 2024 as N3220 by the working group ISO/IEC JTC1/SC22 /WG14. [ 33 ] Historically, embedded C programming requires non-standard extensions to the C language to support exotic features such as fixed-point arithmetic , multiple distinct memory banks , and basic I/O operations. In 2008, the C Standards Committee published a technical report extending the C language [ 34 ] to address these issues by providing a common standard for all implementations to adhere to. It includes a number of features not available in normal C, such as fixed-point arithmetic, named address spaces, and basic I/O hardware addressing. C has a formal grammar specified by the C standard. [ 35 ] Line endings are generally not significant in C; however, line boundaries do have significance during the preprocessing phase. Comments may appear either between the delimiters /* and */ , or (since C99) following // until the end of the line. Comments delimited by /* and */ do not nest, and these sequences of characters are not interpreted as comment delimiters if they appear inside string or character literals. [ 36 ] C source files contain declarations and function definitions. Function definitions, in turn, contain declarations and statements . Declarations either define new types using keywords such as struct , union , and enum , or assign types to and perhaps reserve storage for new variables, usually by writing the type followed by the variable name. Keywords such as char and int specify built-in types. Sections of code are enclosed in braces ( { and } , sometimes called "curly brackets") to limit the scope of declarations and to act as a single statement for control structures. As an imperative language, C uses statements to specify actions. The most common statement is an expression statement , consisting of an expression to be evaluated, followed by a semicolon; as a side effect of the evaluation, functions may be called and variables assigned new values. To modify the normal sequential execution of statements, C provides several control-flow statements identified by reserved keywords. Structured programming is supported by if ... [ else ] conditional execution and by do ... while , while , and for iterative execution (looping). The for statement has separate initialization, testing, and reinitialization expressions, any or all of which can be omitted. break and continue can be used within the loop. Break is used to leave the innermost enclosing loop statement and continue is used to skip to its reinitialisation. There is also a non-structured goto statement, which branches directly to the designated label within the function. switch selects a case to be executed based on the value of an integer expression. Different from many other languages, control-flow will fall through to the next case unless terminated by a break . Expressions can use a variety of built-in operators and may contain function calls. The order in which arguments to functions and operands to most operators are evaluated is unspecified. The evaluations may even be interleaved. However, all side effects (including storage to variables) will occur before the next " sequence point "; sequence points include the end of each expression statement, and the entry to and return from each function call. Sequence points also occur during evaluation of expressions containing certain operators ( && , || , ?: and the comma operator ). This permits a high degree of object code optimization by the compiler, but requires C programmers to take more care to obtain reliable results than is needed for other programming languages. Kernighan and Ritchie say in the Introduction of The C Programming Language : "C, like any other language, has its blemishes. Some of the operators have the wrong precedence; some parts of the syntax could be better." [ 37 ] The C standard did not attempt to correct many of these blemishes, because of the impact of such changes on already existing software. The basic C source character set includes the following characters: [ 38 ] Lowercase and uppercase letters of the ISO basic Latin alphabet : a – z , A – Z Decimal digits: 0 – 9 Graphic characters: ! " # % & ' ( ) * + , - . / : ; < = > ? [ \ ] ^ _ { | } ~ Whitespace characters : space , horizontal tab , vertical tab , form feed , newline The newline character indicates the end of a text line; it need not correspond to an actual single character, although for convenience C treats it as such. The POSIX standard mandates a portable character set which adds a few characters (notably "@") to the basic C source character set. Both standards do not prescribe any particular value encoding— ASCII and EBCDIC both comply with these standards, since they include at least those basic characters, even though they use different encoded values for those characters. Additional multi-byte encoded characters may be used in string literals , but they are not entirely portable . Since C99 multi-national Unicode characters can be embedded portably within C source text by using \uXXXX or \UXXXXXXXX encoding (where X denotes a hexadecimal character). The basic C execution character set contains the same characters, along with representations for the null character , alert , backspace , and carriage return . [ 38 ] Run-time support for extended character sets has increased with each revision of the C standard. All versions of C have reserved words that are case sensitive . As reserved words, they cannot be used for variable names. C89 has 32 reserved words: auto break case char const continue default do double else enum extern float for goto if int long register return short signed sizeof static struct switch typedef union unsigned void volatile while C99 added five more reserved words: (‡ indicates an alternative spelling alias for a C23 keyword) inline restrict _Bool ‡ _Complex _Imaginary C11 added seven more reserved words: [ 39 ] (‡ indicates an alternative spelling alias for a C23 keyword) _Alignas ‡ _Alignof ‡ _Atomic _Generic _Noreturn _Static_assert ‡ _Thread_local ‡ C23 reserved fifteen more words: alignas alignof bool constexpr false nullptr static_assert thread_local true typeof typeof_unqual _BitInt _Decimal32 _Decimal64 _Decimal128 Most of the recently reserved words begin with an underscore followed by a capital letter, because identifiers of that form were previously reserved by the C standard for use only by implementations. Since existing program source code should not have been using these identifiers, it would not be affected when C implementations started supporting these extensions to the programming language. Some standard headers do define more convenient synonyms for underscored identifiers. Some of those words were added as keywords with their conventional spelling in C23 and the corresponding macros were removed. Prior to C89, entry was reserved as a keyword. In the second edition of their book The C Programming Language , which describes what became known as C89, Kernighan and Ritchie wrote, "The ... [keyword] entry , formerly reserved but never used, is no longer reserved." and "The stillborn entry keyword is withdrawn." [ 40 ] C supports a rich set of operators , which are symbols used within an expression to specify the manipulations to be performed while evaluating that expression. C has operators for: arithmetic : + , - , * , / , % assignment : = augmented assignment : += ,   -= ,   *= ,   /= ,   %= ,   &= ,   |= ,   ^= ,   <<= ,   >>= bitwise logic : ~ , & , | , ^ bitwise shifts : << , >> Boolean logic : ! , && , || conditional evaluation : ? : equality testing: == , != calling functions : ( ) increment and decrement : ++ , -- member selection : . , -> object size: sizeof type: typeof , typeof_unqual since C23 order relations : < , <= , > , >= reference and dereference : & , * , [ ] sequencing: , subexpression grouping : ( ) type conversion : ( typename ) C uses the operator = (used in mathematics to express equality) to indicate assignment, following the precedent of Fortran and PL/I , but unlike ALGOL and its derivatives. C uses the operator == to test for equality. The similarity between the operators for assignment and equality may result in the accidental use of one in place of the other, and in many cases the mistake does not produce an error message (although some compilers produce warnings). For example, the conditional expression if (a == b + 1) might mistakenly be written as if (a = b + 1) , which will be evaluated as true unless the value of a is 0 after the assignment. [ 41 ] The C operator precedence is not always intuitive. For example, the operator == binds more tightly than (is executed prior to) the operators & (bitwise AND) and | (bitwise OR) in expressions such as x & 1 == 0 , which must be written as (x & 1) == 0 if that is the coder's intent. [ 42 ] The type system in C is static and weakly typed , which makes it similar to the type system of ALGOL descendants such as Pascal . [ 43 ] There are built-in types for integers of various sizes, both signed and unsigned, floating-point numbers , and enumerated types ( enum ). Integer type char is often used for single-byte characters. C99 added a Boolean data type . There are also derived types including arrays , pointers , records ( struct ), and unions ( union ). C is often used in low-level systems programming where escapes from the type system may be necessary. The compiler attempts to ensure type correctness of most expressions, but the programmer can override the checks in various ways, either by using a type cast to explicitly convert a value from one type to another, or by using pointers or unions to reinterpret the underlying bits of a data object in some other way. Some find C's declaration syntax unintuitive, particularly for function pointers . (Ritchie's idea was to declare identifiers in contexts resembling their use: " declaration reflects use ".) [ 44 ] C's usual arithmetic conversions allow for efficient code to be generated, but can sometimes produce unexpected results. For example, a comparison of signed and unsigned integers of equal width requires a conversion of the signed value to unsigned. This can generate unexpected results if the signed value is negative. C supports the use of pointers , a type of reference that records the address or location of an object or function in memory. Pointers can be dereferenced to access data stored at the address pointed to, or to invoke a pointed-to function. Pointers can be manipulated using assignment or pointer arithmetic . The run-time representation of a pointer value is typically a raw memory address (perhaps augmented by an offset-within-word field), but since a pointer's type includes the type of the thing pointed to, expressions including pointers can be type-checked at compile time. Pointer arithmetic is automatically scaled by the size of the pointed-to data type. Pointers are used for many purposes in C. Text strings are commonly manipulated using pointers into arrays of characters. Dynamic memory allocation is performed using pointers; the result of a malloc is usually cast to the data type of the data to be stored. Many data types, such as trees , are commonly implemented as dynamically allocated struct objects linked together using pointers. Pointers to other pointers are often used in multi-dimensional arrays and arrays of struct objects. Pointers to functions ( function pointers ) are useful for passing functions as arguments to higher-order functions (such as qsort or bsearch ), in dispatch tables , or as callbacks to event handlers . [ 18 ] A null pointer value explicitly points to no valid location. Dereferencing a null pointer value is undefined, often resulting in a segmentation fault . Null pointer values are useful for indicating special cases such as no "next" pointer in the final node of a linked list , or as an error indication from functions returning pointers. In appropriate contexts in source code, such as for assigning to a pointer variable, a null pointer constant can be written as 0 , with or without explicit casting to a pointer type, as the NULL macro defined by several standard headers or, since C23 with the constant nullptr . In conditional contexts, null pointer values evaluate to false , while all other pointer values evaluate to true . Void pointers ( void * ) point to objects of unspecified type, and can therefore be used as "generic" data pointers. Since the size and type of the pointed-to object is not known, void pointers cannot be dereferenced, nor is pointer arithmetic on them allowed, although they can easily be (and in many contexts implicitly are) converted to and from any other object pointer type. [ 18 ] Careless use of pointers is potentially dangerous. Because they are typically unchecked, a pointer variable can be made to point to any arbitrary location, which can cause undesirable effects. Although properly used pointers point to safe places, they can be made to point to unsafe places by using invalid pointer arithmetic ; the objects they point to may continue to be used after deallocation ( dangling pointers ); they may be used without having been initialized ( wild pointers ); or they may be directly assigned an unsafe value using a cast, union, or through another corrupt pointer. In general, C is permissive in allowing manipulation of and conversion between pointer types, although compilers typically provide options for various levels of checking. Some other programming languages address these problems by using more restrictive reference types. Array types in C are traditionally of a fixed, static size specified at compile time. The more recent C99 standard also allows a form of variable-length arrays. However, it is also possible to allocate a block of memory (of arbitrary size) at run time, using the standard library's malloc function, and treat it as an array. Since arrays are always accessed (in effect) via pointers, array accesses are typically not checked against the underlying array size, although some compilers may provide bounds checking as an option. [ 45 ] [ 46 ] Array bounds violations are therefore possible and can lead to various repercussions, including illegal memory accesses, corruption of data, buffer overruns , and run-time exceptions. C does not have a special provision for declaring multi-dimensional arrays , but rather relies on recursion within the type system to declare arrays of arrays, which effectively accomplishes the same thing. The index values of the resulting "multi-dimensional array" can be thought of as increasing in row-major order . Multi-dimensional arrays are commonly used in numerical algorithms (mainly from applied linear algebra ) to store matrices. The structure of the C array is well suited to this particular task. However, in early versions of C the bounds of the array must be known fixed values or else explicitly passed to any subroutine that requires them, and dynamically sized arrays of arrays cannot be accessed using double indexing. (A workaround for this was to allocate the array with an additional "row vector" of pointers to the columns.) C99 introduced "variable-length arrays" which address this issue. The following example using modern C (C99 or later) shows allocation of a two-dimensional array on the heap and the use of multi-dimensional array indexing for accesses (which can use bounds-checking on many C compilers): int func ( int n , int m ) { float ( * p )[ n ][ m ] = malloc ( sizeof * p ); if ( p == NULL ) { return -1 ; } for ( int i = 0 ; i < n ; i ++ ) { for ( int j = 0 ; j < m ; j ++ ) { ( * p )[ i ][ j ] = i + j ; } } print_array ( n , m , p ); free ( p ); return 1 ; } And here is a similar implementation using C99's Auto VLA feature: [ f ] int func ( int n , int m ) { // Caution: checks should be made to ensure n * m * sizeof(float) does NOT exceed limitations for auto VLAs and is within available size of stack. float p [ n ][ m ]; // auto VLA is held on the stack, and sized when the function is invoked for ( int i = 0 ; i < n ; i ++ ) { for ( int j = 0 ; j < m ; j ++ ) { p [ i ][ j ] = i + j ; } } print_array ( n , m , p ); // no need to free(p) since it will disappear when the function exits, along with the rest of the stack frame return 1 ; } Array–pointer interchangeability [ edit ] The subscript notation x[i] (where x designates a pointer) is syntactic sugar for *(x+i) . [ 47 ] Taking advantage of the compiler's knowledge of the pointer type, the address that x + i points to is not the base address (pointed to by x ) incremented by i bytes, but rather is defined to be the base address incremented by i multiplied by the size of an element that x points to. Thus, x[i] designates the i+1 th element of the array. Furthermore, in most expression contexts (a notable exception is as operand of sizeof ), an expression of array type is automatically converted to a pointer to the array's first element. This implies that an array is never copied as a whole when named as an argument to a function, but rather only the address of its first element is passed. Therefore, although function calls in C use pass-by-value semantics, arrays are in effect passed by reference . The total size of an array x can be determined by applying sizeof to an expression of array type. The size of an element can be determined by applying the operator sizeof to any dereferenced element of an array A , as in n = sizeof A[0] . Thus, the number of elements in a declared array A can be determined as sizeof A / sizeof A[0] . Note, that if only a pointer to the first element is available as it is often the case in C code because of the automatic conversion described above, the information about the full type of the array and its length are lost. One of the most important functions of a programming language is to provide facilities for managing memory and the objects that are stored in memory. C provides three principal ways to allocate memory for objects: [ 18 ] Static memory allocation : space for the object is provided in the binary at compile time; these objects have an extent (or lifetime) as long as the binary which contains them is loaded into memory. Automatic memory allocation : temporary objects can be stored on the stack , and this space is automatically freed and reusable after the block in which they are declared is exited. Dynamic memory allocation : blocks of memory of arbitrary size can be requested at run time using library functions such as malloc from a region of memory called the heap ; these blocks persist until subsequently freed for reuse by calling the library function realloc or free . These three approaches are appropriate in different situations and have various trade-offs. For example, static memory allocation has little allocation overhead, automatic allocation may involve slightly more overhead, and dynamic memory allocation can potentially have a great deal of overhead for both allocation and deallocation. The persistent nature of static objects is useful for maintaining state information across function calls, automatic allocation is easy to use but stack space is typically much more limited and transient than either static memory or heap space, and dynamic memory allocation allows convenient allocation of objects whose size is known only at run time. Most C programs make extensive use of all three. Where possible, automatic or static allocation is usually simplest because the storage is managed by the compiler, freeing the programmer of the potentially error-prone chore of manually allocating and releasing storage. However, many data structures can change in size at run time, and since static allocations (and automatic allocations before C99) must have a fixed size at compile time, there are many situations in which dynamic allocation is necessary. [ 18 ] Prior to the C99 standard, variable-sized arrays were a common example of this. (See the article on C dynamic memory allocation for an example of dynamically allocated arrays.) Unlike automatic allocation, which can fail at run time with uncontrolled consequences, the dynamic allocation functions return an indication (in the form of a null pointer value) when the required storage cannot be allocated. (Static allocation that is too large is usually detected by the linker or loader , before the program can even begin execution.) Unless otherwise specified, static objects contain zero or null pointer values upon program startup. Automatically and dynamically allocated objects are initialized only if an initial value is explicitly specified; otherwise they initially have indeterminate values (typically, whatever bit pattern happens to be present in the storage , which might not even represent a valid value for that type). If the program attempts to access an uninitialized value, the results are undefined. Many modern compilers try to detect and warn about this problem, but both false positives and false negatives can occur. Heap memory allocation has to be synchronized with its actual usage in any program to be reused as much as possible. For example, if the only pointer to a heap memory allocation goes out of scope or has its value overwritten before it is deallocated explicitly, then that memory cannot be recovered for later reuse and is essentially lost to the program, a phenomenon known as a memory leak . Conversely, it is possible for memory to be freed but referenced subsequently, leading to unpredictable results. Typically, the failure symptoms appear in a portion of the program unrelated to the code that causes the error, making it difficult to diagnose the failure. Such issues are ameliorated in languages with automatic garbage collection . The C programming language uses libraries as its primary method of extension. In C, a library is a set of functions contained within a single "archive" file. Each library typically has a header file , which contains the prototypes of the functions contained within the library that may be used by a program, and declarations of special data types and macro symbols used with these functions. For a program to use a library, it must include the library's header file, and the library must be linked with the program, which in many cases requires compiler flags (e.g., -lm , shorthand for "link the math library"). [ 18 ] The most common C library is the C standard library , which is specified by the ISO and ANSI C standards and comes with every C implementation (implementations which target limited environments such as embedded systems may provide only a subset of the standard library). This library supports stream input and output, memory allocation, mathematics, character strings, and time values. Several separate standard headers (for example, stdio.h ) specify the interfaces for these and other standard library facilities. Another common set of C library functions are those used by applications specifically targeted for Unix and Unix-like systems, especially functions which provide an interface to the kernel . These functions are detailed in various standards such as POSIX and the Single UNIX Specification . Since many programs have been written in C, there are a wide variety of other libraries available. Libraries are often written in C because C compilers generate efficient object code ; programmers then create interfaces to the library so that the routines can be used from higher-level languages like Java , Perl , and Python . [ 18 ] File handling and streams [ edit ] File input and output (I/O) is not part of the C language itself but instead is handled by libraries (such as the C standard library) and their associated header files (e.g. stdio.h ). File handling is generally implemented through high-level I/O which works through streams . A stream is from this perspective a data flow that is independent of devices, while a file is a concrete device. The high-level I/O is done through the association of a stream to a file. In the C standard library, a buffer (a memory area or queue) is temporarily used to store data before it is sent to the final destination. This reduces the time spent waiting for slower devices, for example a hard drive or solid-state drive . Low-level I/O functions are not part of the standard C library [ clarification needed ] but are generally part of "bare metal" programming (programming that is independent of any operating system such as most embedded programming ). With few exceptions, implementations include low-level I/O. A number of tools have been developed to help C programmers find and fix statements with undefined behavior or possibly erroneous expressions, with greater rigor than that provided by the compiler. Automated source code checking and auditing tools exist, such as Lint . A common practice is to use Lint to detect questionable code when a program is first written. Once a program passes Lint, it is then compiled using the C compiler. Also, many compilers can optionally warn about syntactically valid constructs that are likely to actually be errors. MISRA C is a proprietary set of guidelines to avoid such questionable code, developed for embedded systems. [ 48 ] There are also compilers, libraries, and operating system level mechanisms for performing actions that are not a standard part of C, such as bounds checking for arrays, detection of buffer overflow , serialization , dynamic memory tracking, and automatic garbage collection . Memory management checking tools like Purify or Valgrind and linking with libraries containing special versions of the memory allocation functions can help uncover run-time errors in memory usage. [ 49 ] [ 50 ] C has been widely used to implement end-user and system-level applications. [ 51 ] Rationale for use in systems programming [ edit ] Some software written in C C is widely used for systems programming in implementing operating systems and embedded system applications. [ 52 ] This is for several reasons: The C language permits platform hardware and memory to be accessed with pointers and type punning , so system-specific features (e.g. Control/Status Registers , I/O registers ) can be configured and used with code written in C – it allows fullest control of the platform it is running on. The code generated by compilation does not demand many system features , and can be invoked from some boot code in a straightforward manner – it is simple to execute. The C language statements and expressions typically map well to sequences of instructions for the target processor, and consequently there is a low run-time demand on system resources – it is fast to execute. With its rich set of operators, the C language can use many of the features of target CPUs. Where a particular CPU has more esoteric instructions, a language variant can be constructed with perhaps intrinsic functions to exploit those instructions – it can use practically all the target CPU's features. The language makes it easy to overlay structures onto blocks of binary data, allowing the data to be comprehended, navigated and modified – it can write data structures, even file systems. The language supports a rich set of operators, including bit manipulation, for integer arithmetic and logic, and perhaps different sizes of floating point numbers – it can process appropriately structured data effectively. C is a fairly small language, with only a handful of statements, and without too many features that generate extensive target code – it is comprehensible. C has direct control over memory allocation and deallocation, which gives reasonable efficiency and predictable timing to memory-handling operations, without any concerns for sporadic stop-the-world garbage collection events – it has predictable performance. C permits the use and implementation of different memory allocation schemes, including a typical malloc and free ; a more sophisticated mechanism with arenas ; or a version for an OS kernel that may suit DMA , use within interrupt handlers , or integrated with the virtual memory system. Depending on the linker and environment, C code can also call libraries written in assembly language , and may be called from assembly language – it interoperates well with other lower-level code. C and its calling conventions and linker structures are commonly used in conjunction with other high-level languages, with calls both to C and from C supported – it interoperates well with other high-level code. C has a mature and broad ecosystem, including libraries, frameworks, open source compilers, debuggers and utilities, and is the de facto standard. It is likely the drivers already exist in C, or that there is a similar CPU architecture as a back-end of a C compiler, so there is reduced incentive to choose another language. Computer games are often built from a combination of languages. C has featured significantly, especially for those games attempting to obtain best performance from computer platforms. Examples include Doom from 1993. [ 53 ] Historically, C was sometimes used for web development using the Common Gateway Interface (CGI) as a "gateway" for information between the web application, the server, and the browser. [ 54 ] C may have been chosen over interpreted languages because of its speed, stability, and near-universal availability. [ 55 ] It is no longer common practice for web development to be done in C, [ 56 ] and many other web development languages are popular. Applications where C-based web development continues include the HTTP configuration pages on routers , IoT devices and similar, although even here some projects have parts in higher-level languages e.g. the use of Lua within OpenWRT . Two popular web servers , Apache HTTP Server and Nginx , are written in C. [ 57 ] [ 58 ] [ better source needed ] C's close-to-the-metal approach allows for the construction of these high-performance software systems. [ citation needed ] C as an intermediate language [ edit ] C is sometimes used as an intermediate language by implementations of other languages. This approach may be used for portability or convenience; by using C as an intermediate language, additional machine-specific code generators are not necessary. C has some features, such as line-number preprocessor directives and optional superfluous commas at the end of initializer lists, that support compilation of generated code. However, some of C's shortcomings have prompted the development of other C-based languages specifically designed for use as intermediate languages, such as C-- . Also, contemporary major compilers GCC and LLVM both feature an intermediate representation that is not C, and those compilers support front ends for many languages including C. Computationally intensive libraries [ edit ] C enables programmers to create efficient implementations of algorithms and data structures, because the layer of abstraction from hardware is thin, and its overhead is low, an important criterion for computationally intensive programs. For example, the GNU Multiple Precision Arithmetic Library , the GNU Scientific Library , Mathematica , and MATLAB are completely or partially written in C. Many languages support calling library functions in C; for example, the Python -based framework NumPy uses C for the high-performance and hardware-interacting aspects. Other languages are written in C [ edit ] A consequence of C's wide availability and efficiency is that compilers , libraries and interpreters of other programming languages are often implemented in C. [ 59 ] For example, the reference implementations of Python , [ 60 ] Perl , [ 61 ] Ruby , [ 62 ] and PHP [ 63 ] are written in C. Ritchie himself joked about the limitations of the language that he created: [ 64 ] the power of assembly language and the convenience of ... assembly language — Dennis Ritchie While C is popular, influential and hugely successful, it has drawbacks, including: The standard dynamic memory handling with malloc and free is prone to mistakes. Improper use can lead to memory leaks and dangling pointers . [ 65 ] The use of pointers and the direct manipulation of memory means corruption of memory is possible. There is type checking , yet it does not apply to some areas like variadic functions , and the type checking can be trivially or inadvertently circumvented. It is weakly typed , despite being statically typed. Since the code generated by the compiler contains few run-time checks, there is a burden on the programmer to consider all possible outcomes, to protect against buffer overruns, array bounds checking, stack overflows , memory exhaustion, and consider race conditions , thread isolation, etc. The use of pointers and the run-time manipulation of these enables two ways to access the same data (aliasing), which is not always determinable at compile time. This means that some optimizations that may be available to some other languages, such as Fortran, are not possible in C. For this reason, Fortran is sometimes considered faster. [ citation needed ] Some of the standard library functions, e.g. scanf or strncat , can lead to buffer overruns . There is limited standardization in support for low-level variants in generated code, such as different function calling conventions and ABIs ; different structure packing conventions; and different byte ordering within larger integers (including endianness). In many language implementations, some of these options may be handled with the preprocessor directive #pragma , [ 66 ] [ 67 ] and some with additional keywords e.g. use __cdecl calling convention. The directive and options are not consistently supported. [ 68 ] String handling using the standard library is code-intensive, with explicit memory management required. The language does not directly support object orientation, introspection , run-time expression evaluation (like eval in JavaScript), garbage collection, etc. There are few guards against misuse of language features, which may enable unmaintainable code. In particular, the C preprocessor can hide troubling effects such as double evaluation and worse. [ 69 ] This capability for obfuscated code has been celebrated with competitions such as the International Obfuscated C Code Contest and the Underhanded C Contest . C lacks standard support for exception handling and only offers return codes for error checking. The setjmp and longjmp standard library functions have been used [ 70 ] to implement a try-catch mechanism via macros. Also, goto statements are commonly used for error handling. [ citation needed ] Mitigations for C's problems [ edit ] For some purposes, restricted styles of C have been adopted, e.g. MISRA C or CERT C , in an attempt to reduce the opportunity for unwanted behaviour. [ 71 ] Databases such as CWE attempt to count the ways that systems in general, especially those coded in C, have potential vulnerabilities, along with recommendations for mitigation. There are tools that can mitigate some of the drawbacks. Contemporary C compilers include checks which may generate warnings to help identify many potential bugs. C's use of pointers can be made less risky by use of instruction set architecture extensions such as CHERI or Permission Overlay Extensions . These techniques change the fundamental nature of pointers at a hardware level to include bounds checks and purposes, which can help prevent buffer over-runs and inappropriate heap accesses. Since the early 2020s the Linux kernel has sections written in Rust , a language which has specific measures to improve safety. [ 72 ] TIOBE index Many languages developed after C were influenced by and borrowed aspects of C, including C++ , C# , C shell , D , Go , Java , JavaScript , Julia , Limbo , LPC , Objective-C , Perl , PHP , Python , Ruby , Rust , Swift , Verilog and SystemVerilog . [ 8 ] [ 73 ] Some claim that the most pervasive influence has been syntactical – that these languages combine the statement and expression syntax of C with type systems, data models and large-scale program structures that differ from those of C, sometimes radically. Several C or near-C interpreters exist, including Ch and CINT , which can also be used for scripting. When object-oriented programming languages became popular, C++ and Objective-C were two different extensions of C that provided object-oriented capabilities. Both languages were originally implemented as source-to-source compilers ; source code was translated into C, and then compiled with a C compiler. [ 74 ] The C++ programming language (originally named "C with Classes ") was devised by Bjarne Stroustrup as an approach to providing object-oriented functionality with a C-like syntax. [ 75 ] C++ adds greater typing strength, scoping, and other tools useful in object-oriented programming, and permits generic programming via templates. Nearly a superset of C, C++ now [ when? ] supports most of C, with a few exceptions . Objective-C was originally a thin layer on top of C, and remains a strict superset of C that permits object-oriented programming using a hybrid dynamic/static typing paradigm. Objective-C derives its syntax from both C and Smalltalk : syntax that involves preprocessing, expressions, function declarations, and function calls is inherited from C, while the syntax for object-oriented features was originally taken from Smalltalk. In addition to C++ and Objective-C , Ch , Cilk , and Unified Parallel C are nearly supersets of C. Comparison of Pascal and C Comparison of programming languages List of C compilers List of C programming books Outline of the C programming language ^ "Thompson had made a brief attempt to produce a system coded in an early version of C—before structures—in 1972, but gave up the effort." [ 2 ] [ 3 ] [ 4 ] ^ "The scheme of type composition adopted by C owes considerable debt to Algol 68, although it did not, perhaps, emerge in a form that Algol's adherents would approve of." [ 6 ] [ 7 ] [ 4 ] ^ Pronounced , like the letter ' c ' . [ 9 ] ^ The original example code will compile on most modern compilers that are not in strict standard compliance mode, but it does not fully conform to the requirements of either C89 or C99. In fact, C99 requires that a diagnostic message be produced. ^ Return value 0 is typically used in this context to indicate success. [ 18 ] ^ Code of print_array (not shown) slightly differs also, because of the type of p , being a pointer to the 2D array in the malloc'd version, and just a 2D array in the auto VNA version. ^ a b Prinz, Peter; Crawford, Tony (December 16, 2005). C in a Nutshell . O'Reilly Media, Inc. p. 3. ISBN   978-0-596-55071-4 . ^ Ritchie (1993a) , p. 9. ^ Ritchie (1993b) , p. 9. ^ a b Ritchie (2003) . ^ "N3221 – Editor's Report, Post January 2024 Strasbourg France Meeting" . ISO/IEC JTC1/SC22/WG14 . Open Standards. February 21, 2024 . Retrieved May 24, 2024 . ^ Ritchie (1993a) , p. 8. ^ Ritchie (1993b) , p. 8. ^ a b "Verilog HDL (and C)" (PDF) . The Research School of Computer Science at the Australian National University. June 3, 2010. Archived from the original (PDF) on November 6, 2013 . Retrieved August 19, 2013 . 1980s: Verilog first introduced; Verilog inspired by the C programming language ^ "The name is based on, and pronounced like the letter C in the English alphabet" . the c programming language sound . English Chinese Dictionary. Archived from the original on November 17, 2022 . Retrieved November 17, 2022 . ^ Munoz, Daniel. "After All These Years, the World is Still Powered by C Programming | Toptal" . Toptal Engineering Blog . Retrieved June 15, 2024 . ^ "C Language Drops to Lowest Popularity Rating" . Developer.com . August 9, 2016. Archived from the original on August 22, 2022 . Retrieved August 1, 2022 . ^ a b c d e f g Ritchie (1993a) . ^ "Programming Language Popularity" . 2009. Archived from the original on January 16, 2009 . Retrieved January 16, 2009 . ^ "TIOBE Programming Community Index" . 2009. Archived from the original on May 4, 2009 . Retrieved May 6, 2009 . ^ Ward, Terry A. (August 1983). "Annotated C / A Bibliography of the C Language" . Byte . p. 268 . Retrieved January 31, 2015 . ^ "TIOBE Index for September 2024" . Archived from the original on September 18, 2024 . Retrieved December 16, 2025 . ^ Kernighan & Ritchie (1978) , p. 6. ^ a b c d e f g Klemens, Ben (2013). 21st Century C . O'Reilly Media . ISBN   978-1-4493-2714-9 . ^ Ritchie, Dennis. "BCPL to B to C" . lysator.liu.se . Archived from the original on December 12, 2019 . Retrieved September 10, 2019 . ^ a b c d e Jensen, Richard (December 9, 2020). " "A damn stupid thing to do"—the origins of C" . Ars Technica . Archived from the original on March 28, 2022 . Retrieved March 28, 2022 . ^ a b Johnson, S. C. ; Ritchie, D. M. (1978). "Portability of C Programs and the UNIX System". Bell System Tech. J . 57 (6): 2021– 2048. CiteSeerX   10.1.1.138.35 . doi : 10.1002/j.1538-7305.1978.tb02141.x . ISSN   0005-8580 . S2CID   17510065 . (Note: The PDF is an OCR scan of the original, and contains a rendering of "IBM 370" as "IBM 310".) ^ McIlroy, M. D. (1987). A Research Unix reader: annotated excerpts from the Programmer's Manual, 1971–1986 (PDF) (Technical report). CSTR. Bell Labs. p. 10. 139. Archived from the original (PDF) on November 11, 2017 . Retrieved February 1, 2015 . ^ Kernighan & Ritchie (1978) . ^ "C manual pages". FreeBSD Miscellaneous Information Manual (FreeBSD 13.0 ed.). May 30, 2011. Archived from the original on January 21, 2021 . Retrieved January 15, 2021 . [1] Archived January 21, 2021, at the Wayback Machine ^ Kernighan & Ritchie (1988) . ^ Stroustrup, Bjarne (2002). Sibling rivalry: C and C++ (PDF) (Report). AT&T Labs. Archived from the original (PDF) on August 24, 2014 . Retrieved April 14, 2014 . ^ "Rationale for American National Standard for Information Systems – Programming Language – C" . Archived from the original on July 17, 2024 . Retrieved July 17, 2024 . ^ C Integrity . International Organization for Standardization. March 30, 1995. Archived from the original on July 25, 2018 . Retrieved July 24, 2018 . ^ "JTC1/SC22/WG14 – C" . Home page . ISO/IEC. Archived from the original on February 12, 2018 . Retrieved June 2, 2011 . ^ Andrew Binstock (October 12, 2011). "Interview with Herb Sutter" . Dr. Dobbs . Archived from the original on August 2, 2013 . Retrieved September 7, 2013 . ^ "ISO/IEC 9899:2024 (en) — N3220 working draft" (PDF) . Retrieved July 11, 2025 . ^ "WG14-N3132 : Revised C23 Schedule" (PDF) . open-std.org . June 4, 2023. Archived from the original (PDF) on June 9, 2023. ^ "WG14-N3220 : Working Draft, C2y" (PDF) . open-std.org . February 21, 2024. Archived from the original (PDF) on February 26, 2024. ^ "TR 18037: Embedded C" (PDF) . open-std.org . April 4, 2006. ISO/IEC JTC1 SC22 WG14 N1169. Archived from the original (PDF) on February 25, 2021 . Retrieved July 26, 2011 . ^ Harbison, Samuel P.; Steele, Guy L. (2002). C: A Reference Manual (5th ed.). Englewood Cliffs, NJ : Prentice Hall . ISBN   978-0-13-089592-9 . Contains a BNF grammar for C. ^ Kernighan & Ritchie (1988) , p. 192. ^ Kernighan & Ritchie (1978) , p. 3. ^ a b "Committee Draft ISO/IEC 9899:TC3: 5.2.1 Character sets" . 2007. ^ "ISO/IEC 9899:201x (ISO C11) Committee Draft" (PDF) . open-std.org . December 2, 2010. Archived from the original (PDF) on December 22, 2017 . Retrieved September 16, 2011 . ^ Kernighan & Ritchie (1988) , pp. 192, 259. ^ "10 Common Programming Mistakes in C++" . Cs.ucr.edu . Archived from the original on October 21, 2008 . Retrieved June 26, 2009 . ^ Schultz, Thomas (2004). C and the 8051 (3rd ed.). Otsego, MI: PageFree Publishing Inc. p. 20. ISBN   978-1-58961-237-2 . Retrieved February 10, 2012 . ^ Feuer, Alan R.; Gehani, Narain H. (March 1982). "Comparison of the Programming Languages C and Pascal". ACM Computing Surveys . 14 (1): 73– 92. doi : 10.1145/356869.356872 . S2CID   3136859 . ^ Kernighan & Ritchie (1988) , p. 122. ^ For example, gcc provides _FORTIFY_SOURCE. "Security Features: Compile Time Buffer Checks (FORTIFY_SOURCE)" . fedoraproject.org. Archived from the original on January 7, 2007 . Retrieved August 5, 2012 . ^ เอี่ยมสิริวงศ์, โอภาศ (2016). Programming with C . Bangkok, Thailand: SE-EDUCATION PUBLIC COMPANY LIMITED. pp.  225– 230. ISBN   978-616-08-2740-4 . ^ Raymond, Eric S. (October 11, 1996). The New Hacker's Dictionary (3rd ed.). MIT Press. p. 432. ISBN   978-0-262-68092-9 . Retrieved August 5, 2012 . ^ "Man Page for lint (freebsd Section 1)" . unix.com . May 24, 2001 . Retrieved July 15, 2014 . ^ Hardison, Nate. "CS107 Valgrind Memcheck" . web.stanford.edu . Retrieved June 23, 2023 . ^ Hastings, Reed; Joyce, Bob. "Purify: Fast Detection of Memory Leaks and Access Errors" (PDF) . Pure Software Inc. : 9. ^ Munoz, Daniel. "After All These Years, the World is Still Powered by C Programming" . Toptal Engineering Blog . Retrieved November 17, 2023 . ^ Dale, Nell B.; Weems, Chip (2014). Programming and problem solving with C++ (6th ed.). Burlington, Massachusetts: Jones & Bartlett Learning. ISBN   978-1-4496-9428-9 . OCLC   894992484 . ^ "Development of Doom" . DoomWiki.org . March 2, 2025 . Retrieved March 2, 2025 . ^ Dr. Dobb's Sourcebook . U.S.: Miller Freeman, Inc. November–December 1995. ^ "Using C for CGI Programming" . linuxjournal.com. March 1, 2005. Archived from the original on February 13, 2010 . Retrieved January 4, 2010 . ^ Perkins, Luc (September 17, 2013). "Web development in C: crazy? Or crazy like a fox?" . Medium . Archived from the original on October 4, 2014 . Retrieved April 8, 2022 . ^ "What programming language does NGINX use?" . ^ "What is Apache and What Does it Do for Website Development?" . February 15, 2022. ^ "C – the mother of all languages" . ICT Academy at IITK . November 13, 2018. Archived from the original on May 31, 2021 . Retrieved October 11, 2022 . ^ "1. Extending Python with C or C++" . Python 3.10.7 documentation . Archived from the original on November 5, 2012 . Retrieved October 11, 2022 . ^ Conrad, Michael (January 22, 2018). "An overview of the Perl 5 engine" . Opensource.com . Archived from the original on May 26, 2022 . Retrieved October 11, 2022 . ^ "To Ruby From C and C++" . Ruby Programming Language . Archived from the original on August 12, 2013 . Retrieved October 11, 2022 . ^ Para, Michael (August 3, 2022). "What is PHP? How to Write Your First PHP Program" . freeCodeCamp . Archived from the original on August 4, 2022 . Retrieved October 11, 2022 . ^ Metz, Cade (October 13, 2011). "Dennis Ritchie: The Shoulders Steve Jobs Stood On" . Wired . Archived from the original on April 12, 2022 . Retrieved April 19, 2022 . ^ Internet Security Research Group. "What is memory safety and why does it matter?" . Prossimo . Retrieved March 3, 2025 . ^ corob-msft (March 31, 2022). "Pragma directives and the __pragma and _Pragma keywords" . Microsoft Learn . Archived from the original on September 24, 2022 . Retrieved September 24, 2022 . ^ "Pragmas (The C Preprocessor)" . GCC, the GNU Compiler Collection . Archived from the original on June 17, 2002 . Retrieved September 24, 2022 . ^ "Pragmas" . Intel C++ Compiler Classic Developer Guide and Reference . Intel. Archived from the original on April 10, 2022 . Retrieved April 10, 2022 . ^ "In praise of the C preprocessor" . apenwarr . August 13, 2007 . Retrieved July 9, 2023 . ^ Roberts, Eric S. (March 21, 1989). "Implementing Exceptions in C" (PDF) . DEC Systems Research Center . SRC-RR-40. Archived from the original (PDF) on January 15, 2017 . Retrieved January 4, 2022 . ^ "Secure Coding Overview" (PDF) . Software Engineering Institute, Carnegie Mellon University . Retrieved December 15, 2025 . ^ "New Linux Patch Confirms: Rust Experiment Is Done, Rust Is Here To Stay" . www.phoronix.com . Retrieved December 15, 2025 . ^ O'Regan, Gerard (September 24, 2015). Pillars of computing : a compendium of select, pivotal technology firms . Springer. ISBN   978-3-319-21464-1 . OCLC   922324121 . ^ Rauchwerger, Lawrence (2004). Languages and compilers for parallel computing : 16th international workshop, LCPC 2003, College Station, TX, USA, October 2–4, 2003 : revised papers . Springer. ISBN   978-3-540-24644-2 . OCLC   57965544 . ^ Stroustrup, Bjarne (1993). "A History of C++: 1979–1991" (PDF) . Archived from the original (PDF) on February 2, 2019 . Retrieved June 9, 2011 . Kernighan, Brian W. ; Ritchie, Dennis M. (1978). The C Programming Language (1st ed.). Englewood Cliffs: Prentice Hall . ISBN   978-0-13-110163-0 . LCCN   77028983 . OCLC   3608698 . OL   4558528M . Wikidata   Q63565563 . Kernighan, Brian W. ; Ritchie, Dennis M. (1988). The C Programming Language (2nd ed.). Upper Saddle River: Prentice Hall . ISBN   978-0-13-110362-7 . LCCN   88005934 . OCLC   254455874 . OL   2030445M . Wikidata   Q63413168 . Ritchie, Dennis M. (March 1993a). Wexelblat, Richard L. (ed.). "The Development of the C Language" . ACM SIGPLAN Notices . 28 (3). New York City: Association for Computing Machinery : 201– 208. doi : 10.1145/155360.155580 . ISSN   0362-1340 . Wikidata   Q55869040 . Ritchie, Dennis M. (1993b). Bergin, Thomas J.; Gibson, Richard G. (eds.). "The Development of the C Language" . The Second ACM SIGPLAN Conference on History of Programming Languages (HOPL-II) . New York City: Association for Computing Machinery : 201– 208. doi : 10.1145/154766.155580 . Wikidata   Q29392176 . Ritchie, Dennis M. (2003) [1993]. The Development of the C Language . Dennis Ritchie . Wikidata   Q134885774 . Archived from the original on January 30, 2025 – via Bell Labs/Lucent Technologies. Plauger, P.J. (1992). The Standard C Library (1 ed.). Prentice Hall. ISBN   978-0-13-131509-9 . (source) Banahan, M.; Brady, D.; Doran, M. (1991). The C Book: Featuring the ANSI C Standard (2 ed.). Addison-Wesley. ISBN   978-0-201-54433-6 . (free) Feuer, Alan R. (1985). The C Puzzle Book (1 ed.). Prentice Hall. ISBN   0-13-109934-5 . Harbison, Samuel; Steele, Guy Jr. (2002). C: A Reference Manual (5 ed.). Pearson. ISBN   978-0-13-089592-9 . (archive) King, K.N. (2008). C Programming: A Modern Approach (2 ed.). W. W. Norton. ISBN   978-0-393-97950-3 . (archive) Griffiths, David; Griffiths, Dawn (2012). Head First C (1 ed.). O'Reilly. ISBN   978-1-4493-9991-7 . Perry, Greg; Miller, Dean (2013). C Programming: Absolute Beginner's Guide (3 ed.). Que. ISBN   978-0-7897-5198-0 . Deitel, Paul; Deitel, Harvey (2015). C: How to Program (8 ed.). Pearson. ISBN   978-0-13-397689-2 . Gustedt, Jens (2019). Modern C (2 ed.). Manning. ISBN   978-1-61729-581-2 . (free) ISO C Working Group official website ISO/IEC 9899 , publicly available official C documents, including the C99 Rationale "C99 with Technical corrigenda TC1, TC2, and TC3 included" (PDF) . Archived from the original (PDF) on October 25, 2007.   (3.61 MB) comp.lang.c Frequently Asked Questions A History of C , by Dennis Ritchie C Library Reference and Examples
Markdown
[Jump to content](https://en.wikipedia.org/wiki/C_\(programming_language\)#bodyContent) Main menu Main menu move to sidebar hide Navigation - [Main page](https://en.wikipedia.org/wiki/Main_Page "Visit the main page [z]") - [Contents](https://en.wikipedia.org/wiki/Wikipedia:Contents "Guides to browsing Wikipedia") - [Current events](https://en.wikipedia.org/wiki/Portal:Current_events "Articles related to current events") - [Random article](https://en.wikipedia.org/wiki/Special:Random "Visit a randomly selected article [x]") - [About Wikipedia](https://en.wikipedia.org/wiki/Wikipedia:About "Learn about Wikipedia and how it works") - [Contact us](https://en.wikipedia.org/wiki/Wikipedia:Contact_us "How to contact Wikipedia") Contribute - [Help](https://en.wikipedia.org/wiki/Help:Contents "Guidance on how to use and edit Wikipedia") - [Learn to edit](https://en.wikipedia.org/wiki/Help:Introduction "Learn how to edit Wikipedia") - [Community portal](https://en.wikipedia.org/wiki/Wikipedia:Community_portal "The hub for editors") - [Recent changes](https://en.wikipedia.org/wiki/Special:RecentChanges "A list of recent changes to Wikipedia [r]") - [Upload file](https://en.wikipedia.org/wiki/Wikipedia:File_upload_wizard "Add images or other media for use on Wikipedia") - [Special pages](https://en.wikipedia.org/wiki/Special:SpecialPages "A list of all special pages [q]") [![](https://en.wikipedia.org/static/images/icons/enwiki-25.svg) ![Wikipedia](https://en.wikipedia.org/static/images/mobile/copyright/wikipedia-wordmark-en-25.svg) ![The Free Encyclopedia](https://en.wikipedia.org/static/images/mobile/copyright/wikipedia-tagline-en-25.svg)](https://en.wikipedia.org/wiki/Main_Page) [Search](https://en.wikipedia.org/wiki/Special:Search "Search Wikipedia [f]") Appearance - [Donate](https://donate.wikimedia.org/?wmf_source=donate&wmf_medium=sidebar&wmf_campaign=en.wikipedia.org&uselang=en) - [Create account](https://en.wikipedia.org/w/index.php?title=Special:CreateAccount&returnto=C+%28programming+language%29 "You are encouraged to create an account and log in; however, it is not mandatory") - [Log in](https://en.wikipedia.org/w/index.php?title=Special:UserLogin&returnto=C+%28programming+language%29 "You're encouraged to log in; however, it's not mandatory. [o]") Personal tools - [Donate](https://donate.wikimedia.org/?wmf_source=donate&wmf_medium=sidebar&wmf_campaign=en.wikipedia.org&uselang=en) - [Create account](https://en.wikipedia.org/w/index.php?title=Special:CreateAccount&returnto=C+%28programming+language%29 "You are encouraged to create an account and log in; however, it is not mandatory") - [Log in](https://en.wikipedia.org/w/index.php?title=Special:UserLogin&returnto=C+%28programming+language%29 "You're encouraged to log in; however, it's not mandatory. [o]") ## Contents move to sidebar hide - [(Top)](https://en.wikipedia.org/wiki/C_\(programming_language\)) - [1 Characteristics](https://en.wikipedia.org/wiki/C_\(programming_language\)#Characteristics) - [2 "Hello, world" example](https://en.wikipedia.org/wiki/C_\(programming_language\)#"Hello,_world"_example) - [3 History](https://en.wikipedia.org/wiki/C_\(programming_language\)#History) Toggle History subsection - [3\.1 Early developments](https://en.wikipedia.org/wiki/C_\(programming_language\)#Early_developments) - [3\.1.1 B](https://en.wikipedia.org/wiki/C_\(programming_language\)#B) - [3\.1.2 New B and first C release](https://en.wikipedia.org/wiki/C_\(programming_language\)#New_B_and_first_C_release) - [3\.1.3 Structures and Unix kernel re-write](https://en.wikipedia.org/wiki/C_\(programming_language\)#Structures_and_Unix_kernel_re-write) - [3\.2 K\&R C](https://en.wikipedia.org/wiki/C_\(programming_language\)#K&R_C) - [3\.3 ANSI C and ISO C](https://en.wikipedia.org/wiki/C_\(programming_language\)#ANSI_C_and_ISO_C) - [3\.4 C99](https://en.wikipedia.org/wiki/C_\(programming_language\)#C99) - [3\.5 C11](https://en.wikipedia.org/wiki/C_\(programming_language\)#C11) - [3\.6 C17](https://en.wikipedia.org/wiki/C_\(programming_language\)#C17) - [3\.7 C23](https://en.wikipedia.org/wiki/C_\(programming_language\)#C23) - [3\.8 C2Y](https://en.wikipedia.org/wiki/C_\(programming_language\)#C2Y) - [3\.9 Embedded C](https://en.wikipedia.org/wiki/C_\(programming_language\)#Embedded_C) - [4 Definition](https://en.wikipedia.org/wiki/C_\(programming_language\)#Definition) Toggle Definition subsection - [4\.1 Character set](https://en.wikipedia.org/wiki/C_\(programming_language\)#Character_set) - [4\.2 Reserved words](https://en.wikipedia.org/wiki/C_\(programming_language\)#Reserved_words) - [4\.3 Operators](https://en.wikipedia.org/wiki/C_\(programming_language\)#Operators) - [4\.4 Data types](https://en.wikipedia.org/wiki/C_\(programming_language\)#Data_types) - [4\.4.1 Pointers](https://en.wikipedia.org/wiki/C_\(programming_language\)#Pointers) - [4\.4.2 Arrays](https://en.wikipedia.org/wiki/C_\(programming_language\)#Arrays) - [4\.4.3 Array–pointer interchangeability](https://en.wikipedia.org/wiki/C_\(programming_language\)#Array%E2%80%93pointer_interchangeability) - [4\.5 Memory management](https://en.wikipedia.org/wiki/C_\(programming_language\)#Memory_management) - [4\.6 Libraries](https://en.wikipedia.org/wiki/C_\(programming_language\)#Libraries) - [4\.6.1 File handling and streams](https://en.wikipedia.org/wiki/C_\(programming_language\)#File_handling_and_streams) - [5 Language tools](https://en.wikipedia.org/wiki/C_\(programming_language\)#Language_tools) - [6 Uses](https://en.wikipedia.org/wiki/C_\(programming_language\)#Uses) Toggle Uses subsection - [6\.1 Rationale for use in systems programming](https://en.wikipedia.org/wiki/C_\(programming_language\)#Rationale_for_use_in_systems_programming) - [6\.2 Games](https://en.wikipedia.org/wiki/C_\(programming_language\)#Games) - [6\.3 World Wide Web](https://en.wikipedia.org/wiki/C_\(programming_language\)#World_Wide_Web) - [6\.4 C as an intermediate language](https://en.wikipedia.org/wiki/C_\(programming_language\)#C_as_an_intermediate_language) - [6\.5 Computationally intensive libraries](https://en.wikipedia.org/wiki/C_\(programming_language\)#Computationally_intensive_libraries) - [6\.6 Other languages are written in C](https://en.wikipedia.org/wiki/C_\(programming_language\)#Other_languages_are_written_in_C) - [7 Limitations](https://en.wikipedia.org/wiki/C_\(programming_language\)#Limitations) Toggle Limitations subsection - [7\.1 Mitigations for C's problems](https://en.wikipedia.org/wiki/C_\(programming_language\)#Mitigations_for_C's_problems) - [8 Related languages](https://en.wikipedia.org/wiki/C_\(programming_language\)#Related_languages) - [9 See also](https://en.wikipedia.org/wiki/C_\(programming_language\)#See_also) - [10 Notes](https://en.wikipedia.org/wiki/C_\(programming_language\)#Notes) - [11 References](https://en.wikipedia.org/wiki/C_\(programming_language\)#References) - [12 Sources](https://en.wikipedia.org/wiki/C_\(programming_language\)#Sources) - [13 Further reading](https://en.wikipedia.org/wiki/C_\(programming_language\)#Further_reading) - [14 External links](https://en.wikipedia.org/wiki/C_\(programming_language\)#External_links) Toggle the table of contents # C (programming language) 125 languages - [Afrikaans](https://af.wikipedia.org/wiki/C_\(programmeertaal\) "C (programmeertaal) – Afrikaans") - [Alemannisch](https://als.wikipedia.org/wiki/C_\(Programmiersprache\) "C (Programmiersprache) – Alemannic") - [አማርኛ](https://am.wikipedia.org/wiki/%E1%88%B2_\(%E1%8B%A8%E1%8A%AE%E1%88%9D%E1%8D%92%E1%8B%A9%E1%89%B0%E1%88%AD_%E1%8D%8D%E1%88%AD%E1%8C%88%E1%88%9B_%E1%89%8B%E1%8A%95%E1%89%8B\) "ሲ (የኮምፒዩተር ፍርገማ ቋንቋ) – Amharic") - [Aragonés](https://an.wikipedia.org/wiki/Lenguache_de_programaci%C3%B3n_C "Lenguache de programación C – Aragonese") - [العربية](https://ar.wikipedia.org/wiki/%D8%B3%D9%8A_\(%D9%84%D8%BA%D8%A9_%D8%A8%D8%B1%D9%85%D8%AC%D8%A9\) "سي (لغة برمجة) – Arabic") - [الدارجة](https://ary.wikipedia.org/wiki/%D8%B3%D9%8A_\(%D9%84%D9%88%D9%86%DA%AD%D8%A7%D8%AC\) "سي (لونڭاج) – Moroccan Arabic") - [অসমীয়া](https://as.wikipedia.org/wiki/%E0%A6%9A%E0%A6%BF_\(%E0%A6%AA%E0%A7%8D%E0%A7%B0%E0%A6%97%E0%A7%8D%E0%A7%B0%E0%A6%BE%E0%A6%AE%E0%A6%BF%E0%A6%82_%E0%A6%B2%E0%A7%87%E0%A6%82%E0%A6%97%E0%A7%81%E0%A7%B1%E0%A7%87%E0%A6%9C\) "চি (প্ৰগ্ৰামিং লেংগুৱেজ) – Assamese") - [Asturianu](https://ast.wikipedia.org/wiki/Llinguaxe_de_programaci%C3%B3n_C "Llinguaxe de programación C – Asturian") - [Azərbaycanca](https://az.wikipedia.org/wiki/C_\(proqramla%C5%9Fd%C4%B1rma_dili\) "C (proqramlaşdırma dili) – Azerbaijani") - [تۆرکجه](https://azb.wikipedia.org/wiki/%D8%B3%DB%8C_\(%DB%8C%D8%A7%D8%B2%DB%8C%D9%84%DB%8C%D9%85%D9%84%D8%A7%D9%85%D8%A7_%D8%AF%DB%8C%D9%84%DB%8C\) "سی (یازیلیملاما دیلی) – South Azerbaijani") - [Žemaitėška](https://bat-smg.wikipedia.org/wiki/C_\(kalba\) "C (kalba) – Samogitian") - [Беларуская (тарашкевіца)](https://be-tarask.wikipedia.org/wiki/C_\(%D0%BC%D0%BE%D0%B2%D0%B0_%D0%BF%D1%80%D0%B0%D0%B3%D1%80%D0%B0%D0%BC%D0%B0%D0%B2%D0%B0%D0%BD%D1%8C%D0%BD%D1%8F\) "C (мова праграмаваньня) – Belarusian (Taraškievica orthography)") - [Беларуская](https://be.wikipedia.org/wiki/C_\(%D0%BC%D0%BE%D0%B2%D0%B0_%D0%BF%D1%80%D0%B0%D0%B3%D1%80%D0%B0%D0%BC%D0%B0%D0%B2%D0%B0%D0%BD%D0%BD%D1%8F\) "C (мова праграмавання) – Belarusian") - [Български](https://bg.wikipedia.org/wiki/C_\(%D0%B5%D0%B7%D0%B8%D0%BA_%D0%B7%D0%B0_%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D0%B8%D1%80%D0%B0%D0%BD%D0%B5\) "C (език за програмиране) – Bulgarian") - [भोजपुरी](https://bh.wikipedia.org/wiki/%E0%A4%B8%E0%A5%80_\(%E0%A4%AA%E0%A5%8D%E0%A4%B0%E0%A5%8B%E0%A4%97%E0%A5%8D%E0%A4%B0%E0%A4%BE%E0%A4%AE%E0%A4%BF%E0%A4%82%E0%A4%97_%E0%A4%AD%E0%A4%BE%E0%A4%B7%E0%A4%BE\) "सी (प्रोग्रामिंग भाषा) – Bhojpuri") - [ပအိုဝ်ႏဘာႏသာႏ](https://blk.wikipedia.org/wiki/C_\(%E1%80%95%E1%80%9B%E1%80%AD%E1%80%AF%E1%80%82%E1%80%9B%E1%80%99%E1%80%BA%E1%80%99%E1%80%AD%E1%80%89%E1%80%BA%E1%80%B8%E1%80%98%E1%80%AC%E1%82%8F%E1%80%9E%E1%80%AC%E1%82%8F%E1%80%84%E1%80%9D%E1%80%BA%E1%80%B8%E1%80%84%E1%80%BD%E1%80%AB\) "C (ပရိုဂရမ်မိဉ်းဘာႏသာႏငဝ်းငွါ) – Pa'O") - [বাংলা](https://bn.wikipedia.org/wiki/%E0%A6%B8%E0%A6%BF_\(%E0%A6%AA%E0%A7%8D%E0%A6%B0%E0%A7%8B%E0%A6%97%E0%A7%8D%E0%A6%B0%E0%A6%BE%E0%A6%AE%E0%A6%BF%E0%A6%82_%E0%A6%AD%E0%A6%BE%E0%A6%B7%E0%A6%BE\) "সি (প্রোগ্রামিং ভাষা) – Bangla") - [Brezhoneg](https://br.wikipedia.org/wiki/C_\(lavar_programmi%C3%B1\) "C (lavar programmiñ) – Breton") - [Bosanski](https://bs.wikipedia.org/wiki/C_\(programski_jezik\) "C (programski jezik) – Bosnian") - [Basa Ugi](https://bug.wikipedia.org/wiki/C_\(basa_maprogram\) "C (basa maprogram) – Buginese") - [Català](https://ca.wikipedia.org/wiki/Llenguatge_C "Llenguatge C – Catalan") - [閩東語 / Mìng-dĕ̤ng-ngṳ̄](https://cdo.wikipedia.org/wiki/C_ng%E1%B9%B3%CC%84-ngi%C3%B2ng "C ngṳ̄-ngiòng – Mindong") - [Corsu](https://co.wikipedia.org/wiki/C_\(linguagiu_di_prugrammazione\) "C (linguagiu di prugrammazione) – Corsican") - [Čeština](https://cs.wikipedia.org/wiki/C_\(programovac%C3%AD_jazyk\) "C (programovací jazyk) – Czech") - [Чӑвашла](https://cv.wikipedia.org/wiki/%D0%A1%D0%B8_\(%D0%BA%D0%BE%D0%BC%D0%BF%D1%8C%D1%8E%D1%82%D0%B5%D1%80_%D1%87%C4%95%D0%BB%D1%85%D0%B8\) "Си (компьютер чĕлхи) – Chuvash") - [Cymraeg](https://cy.wikipedia.org/wiki/C_\(iaith_raglennu\) "C (iaith raglennu) – Welsh") - [Dansk](https://da.wikipedia.org/wiki/C_\(programmeringssprog\) "C (programmeringssprog) – Danish") - [Deutsch](https://de.wikipedia.org/wiki/C_\(Programmiersprache\) "C (Programmiersprache) – German") - [Ελληνικά](https://el.wikipedia.org/wiki/C_\(%CE%B3%CE%BB%CF%8E%CF%83%CF%83%CE%B1_%CF%80%CF%81%CE%BF%CE%B3%CF%81%CE%B1%CE%BC%CE%BC%CE%B1%CF%84%CE%B9%CF%83%CE%BC%CE%BF%CF%8D\) "C (γλώσσα προγραμματισμού) – Greek") - [Esperanto](https://eo.wikipedia.org/wiki/C_\(programlingvo\) "C (programlingvo) – Esperanto") - [Español](https://es.wikipedia.org/wiki/C_\(lenguaje_de_programaci%C3%B3n\) "C (lenguaje de programación) – Spanish") - [Eesti](https://et.wikipedia.org/wiki/C_\(programmeerimiskeel\) "C (programmeerimiskeel) – Estonian") - [Euskara](https://eu.wikipedia.org/wiki/C_\(programazio_lengoaia\) "C (programazio lengoaia) – Basque") - [فارسی](https://fa.wikipedia.org/wiki/%D8%B3%DB%8C_\(%D8%B2%D8%A8%D8%A7%D9%86_%D8%A8%D8%B1%D9%86%D8%A7%D9%85%D9%87%E2%80%8C%D9%86%D9%88%DB%8C%D8%B3%DB%8C\) "سی (زبان برنامه‌نویسی) – Persian") - [Suomi](https://fi.wikipedia.org/wiki/C_\(ohjelmointikieli\) "C (ohjelmointikieli) – Finnish") - [Français](https://fr.wikipedia.org/wiki/C_\(langage\) "C (langage) – French") - [Gaeilge](https://ga.wikipedia.org/wiki/C_\(Teanga_r%C3%ADomhchl%C3%A1r%C3%BAch%C3%A1in\) "C (Teanga ríomhchlárúcháin) – Irish") - [Galego](https://gl.wikipedia.org/wiki/C_\(linguaxe_de_programaci%C3%B3n\) "C (linguaxe de programación) – Galician") - [ગુજરાતી](https://gu.wikipedia.org/wiki/C_\(%E0%AA%AA%E0%AB%8D%E0%AA%B0%E0%AB%8B%E0%AA%97%E0%AB%8D%E0%AA%B0%E0%AA%BE%E0%AA%AE%E0%AA%BF%E0%AA%82%E0%AA%97_%E0%AA%AD%E0%AA%BE%E0%AA%B7%E0%AA%BE\) "C (પ્રોગ્રામિંગ ભાષા) – Gujarati") - [Hausa](https://ha.wikipedia.org/wiki/C_programming_language "C programming language – Hausa") - [客家語 / Hak-kâ-ngî](https://hak.wikipedia.org/wiki/C_ng%C3%AE-ngi%C3%A8n "C ngî-ngièn – Hakka Chinese") - [עברית](https://he.wikipedia.org/wiki/C_\(%D7%A9%D7%A4%D7%AA_%D7%AA%D7%9B%D7%A0%D7%95%D7%AA\) "C (שפת תכנות) – Hebrew") - [हिन्दी](https://hi.wikipedia.org/wiki/%E0%A4%B8%E0%A5%80_\(%E0%A4%AA%E0%A5%8D%E0%A4%B0%E0%A5%8B%E0%A4%97%E0%A5%8D%E0%A4%B0%E0%A4%BE%E0%A4%AE%E0%A4%BF%E0%A4%82%E0%A4%97_%E0%A4%AD%E0%A4%BE%E0%A4%B7%E0%A4%BE\) "सी (प्रोग्रामिंग भाषा) – Hindi") - [Hrvatski](https://hr.wikipedia.org/wiki/C_\(programski_jezik\) "C (programski jezik) – Croatian") - [Magyar](https://hu.wikipedia.org/wiki/C_\(programoz%C3%A1si_nyelv\) "C (programozási nyelv) – Hungarian") - [Հայերեն](https://hy.wikipedia.org/wiki/%D5%8D%D5%AB_\(%D5%AE%D6%80%D5%A1%D5%A3%D6%80%D5%A1%D5%BE%D5%B8%D6%80%D5%B4%D5%A1%D5%B6_%D5%AC%D5%A5%D5%A6%D5%B8%D6%82\) "Սի (ծրագրավորման լեզու) – Armenian") - [Interlingua](https://ia.wikipedia.org/wiki/C_\(linguage_de_programmation\) "C (linguage de programmation) – Interlingua") - [Bahasa Indonesia](https://id.wikipedia.org/wiki/C_\(bahasa_pemrograman\) "C (bahasa pemrograman) – Indonesian") - [Ido](https://io.wikipedia.org/wiki/C_\(programifo-linguo\) "C (programifo-linguo) – Ido") - [Íslenska](https://is.wikipedia.org/wiki/C_\(forritunarm%C3%A1l\) "C (forritunarmál) – Icelandic") - [Italiano](https://it.wikipedia.org/wiki/C_\(linguaggio_di_programmazione\) "C (linguaggio di programmazione) – Italian") - [日本語](https://ja.wikipedia.org/wiki/C%E8%A8%80%E8%AA%9E "C言語 – Japanese") - [Jawa](https://jv.wikipedia.org/wiki/C_\(basa_pamrograman\) "C (basa pamrograman) – Javanese") - [ქართული](https://ka.wikipedia.org/wiki/C_\(%E1%83%9E%E1%83%A0%E1%83%9D%E1%83%92%E1%83%A0%E1%83%90%E1%83%9B%E1%83%98%E1%83%A0%E1%83%94%E1%83%91%E1%83%98%E1%83%A1_%E1%83%94%E1%83%9C%E1%83%90\) "C (პროგრამირების ენა) – Georgian") - [Qaraqalpaqsha](https://kaa.wikipedia.org/wiki/C_\(programmalast%C4%B1r%C4%B1w_tili\) "C (programmalastırıw tili) – Kara-Kalpak") - [Taqbaylit](https://kab.wikipedia.org/wiki/C_\(tutlayt\) "C (tutlayt) – Kabyle") - [Қазақша](https://kk.wikipedia.org/wiki/C_\(%D0%B1%D0%B0%D2%93%D0%B4%D0%B0%D1%80%D0%BB%D0%B0%D0%BC%D0%B0%D0%BB%D0%B0%D1%83_%D1%82%D1%96%D0%BB%D1%96\) "C (бағдарламалау тілі) – Kazakh") - [ភាសាខ្មែរ](https://km.wikipedia.org/wiki/%E1%9E%97%E1%9E%B6%E1%9E%9F%E1%9E%B6%E1%9E%9F%E1%9F%8A%E1%9E%B8 "ភាសាស៊ី – Khmer") - [ಕನ್ನಡ](https://kn.wikipedia.org/wiki/%E0%B2%B8%E0%B2%BF_\(%E0%B2%95%E0%B3%8D%E0%B2%B0%E0%B2%AE%E0%B2%B5%E0%B2%BF%E0%B2%A7%E0%B2%BF_%E0%B2%AD%E0%B2%BE%E0%B2%B7%E0%B3%86\) "ಸಿ (ಕ್ರಮವಿಧಿ ಭಾಷೆ) – Kannada") - [한국어](https://ko.wikipedia.org/wiki/C_\(%ED%94%84%EB%A1%9C%EA%B7%B8%EB%9E%98%EB%B0%8D_%EC%96%B8%EC%96%B4\) "C (프로그래밍 언어) – Korean") - [Kurdî](https://ku.wikipedia.org/wiki/C_\(ziman%C3%AA_bernamesaziy%C3%AA\) "C (zimanê bernamesaziyê) – Kurdish") - [Кыргызча](https://ky.wikipedia.org/wiki/%D0%A1%D0%B8_\(%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D0%BC%D0%B0%D0%BB%D0%BE%D0%BE_%D1%82%D0%B8%D0%BB%D0%B8\) "Си (программалоо тили) – Kyrgyz") - [Latina](https://la.wikipedia.org/wiki/C_\(lingua_programmationis\) "C (lingua programmationis) – Latin") - [Lombard](https://lmo.wikipedia.org/wiki/C_\(lenguagg\) "C (lenguagg) – Lombard") - [ລາວ](https://lo.wikipedia.org/wiki/%E0%BA%9E%E0%BA%B2%E0%BA%AA%E0%BA%B2%E0%BB%80%E0%BA%8A "ພາສາເຊ – Lao") - [Lietuvių](https://lt.wikipedia.org/wiki/C_\(kalba\) "C (kalba) – Lithuanian") - [Latviešu](https://lv.wikipedia.org/wiki/C_\(programm%C4%93%C5%A1anas_valoda\) "C (programmēšanas valoda) – Latvian") - [मैथिली](https://mai.wikipedia.org/wiki/%E0%A4%B8%E0%A5%80 "सी – Maithili") - [Malagasy](https://mg.wikipedia.org/wiki/Fiteny_C "Fiteny C – Malagasy") - [Македонски](https://mk.wikipedia.org/wiki/C_\(%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D1%81%D0%BA%D0%B8_%D1%98%D0%B0%D0%B7%D0%B8%D0%BA\) "C (програмски јазик) – Macedonian") - [മലയാളം](https://ml.wikipedia.org/wiki/%E0%B4%B8%E0%B4%BF_\(%E0%B4%AA%E0%B5%8D%E0%B4%B0%E0%B5%8B%E0%B4%97%E0%B5%8D%E0%B4%B0%E0%B4%BE%E0%B4%AE%E0%B4%BF%E0%B4%99%E0%B5%8D_%E0%B4%AD%E0%B4%BE%E0%B4%B7\) "സി (പ്രോഗ്രാമിങ് ഭാഷ) – Malayalam") - [Монгол](https://mn.wikipedia.org/wiki/%D0%A1%D0%B8_%D1%85%D1%8D%D0%BB "Си хэл – Mongolian") - [ꯃꯤꯇꯩ ꯂꯣꯟ](https://mni.wikipedia.org/wiki/%EA%AF%81%EA%AF%A4_%EA%AF%84%EA%AF%AD%EA%AF%94%EA%AF%A3%EA%AF%92%EA%AF%AD%EA%AF%94%EA%AF%A5%EA%AF%9D%EA%AF%83%EA%AF%A4%EA%AF%A1_%EA%AF%82%EA%AF%A3%EA%AF%9F "ꯁꯤ ꯄ꯭ꯔꯣꯒ꯭ꯔꯥꯝꯃꯤꯡ ꯂꯣꯟ – Manipuri") - [मराठी](https://mr.wikipedia.org/wiki/%E0%A4%B8%E0%A5%80_\(%E0%A4%86%E0%A4%9C%E0%A5%8D%E0%A4%9E%E0%A4%BE%E0%A4%B5%E0%A4%B2%E0%A5%80_%E0%A4%AD%E0%A4%BE%E0%A4%B7%E0%A4%BE\) "सी (आज्ञावली भाषा) – Marathi") - [Bahasa Melayu](https://ms.wikipedia.org/wiki/C_\(bahasa_pengaturcaraan\) "C (bahasa pengaturcaraan) – Malay") - [မြန်မာဘာသာ](https://my.wikipedia.org/wiki/C_\(%E1%80%95%E1%80%9B%E1%80%AD%E1%80%AF%E1%80%82%E1%80%9B%E1%80%99%E1%80%BA%E1%80%B8%E1%80%99%E1%80%84%E1%80%BA%E1%80%B8_%E1%80%98%E1%80%AC%E1%80%9E%E1%80%AC%E1%80%85%E1%80%80%E1%80%AC%E1%80%B8\) "C (ပရိုဂရမ်းမင်း ဘာသာစကား) – Burmese") - [नेपाली](https://ne.wikipedia.org/wiki/%E0%A4%B8%E0%A4%BF "सि – Nepali") - [Nederlands](https://nl.wikipedia.org/wiki/C_\(programmeertaal\) "C (programmeertaal) – Dutch") - [Norsk nynorsk](https://nn.wikipedia.org/wiki/Programmeringsspr%C3%A5ket_C "Programmeringsspråket C – Norwegian Nynorsk") - [Norsk bokmål](https://no.wikipedia.org/wiki/C_\(programmeringsspr%C3%A5k\) "C (programmeringsspråk) – Norwegian Bokmål") - [Occitan](https://oc.wikipedia.org/wiki/C_\(lengatge\) "C (lengatge) – Occitan") - [ଓଡ଼ିଆ](https://or.wikipedia.org/wiki/%E0%AC%B8%E0%AC%BF_\(%E0%AC%AA%E0%AD%8D%E0%AC%B0%E0%AD%8B%E0%AC%97%E0%AD%8D%E0%AC%B0%E0%AC%BE%E0%AC%AE%E0%AC%BF%E0%AC%82_%E0%AC%AD%E0%AC%BE%E0%AC%B7%E0%AC%BE\) "ସି (ପ୍ରୋଗ୍ରାମିଂ ଭାଷା) – Odia") - [ਪੰਜਾਬੀ](https://pa.wikipedia.org/wiki/%E0%A8%B8%E0%A9%80_\(%E0%A8%AA%E0%A9%8D%E0%A8%B0%E0%A9%8B%E0%A8%97%E0%A8%B0%E0%A8%BE%E0%A8%AE%E0%A8%BF%E0%A9%B0%E0%A8%97_%E0%A8%AD%E0%A8%BE%E0%A8%B8%E0%A8%BC%E0%A8%BE\) "ਸੀ (ਪ੍ਰੋਗਰਾਮਿੰਗ ਭਾਸ਼ਾ) – Punjabi") - [Polski](https://pl.wikipedia.org/wiki/C_\(j%C4%99zyk_programowania\) "C (język programowania) – Polish") - [Piemontèis](https://pms.wikipedia.org/wiki/C_\(lengage_%C3%ABd_programassion\) "C (lengage ëd programassion) – Piedmontese") - [پنجابی](https://pnb.wikipedia.org/wiki/%D8%B3%DB%8C_\(%D9%BE%D8%B1%D9%88%DA%AF%D8%B1%D8%A7%D9%85%D9%86%DA%AF_%D8%B2%D8%A8%D8%A7%D9%86\) "سی (پروگرامنگ زبان) – Western Punjabi") - [Português](https://pt.wikipedia.org/wiki/C_\(linguagem_de_programa%C3%A7%C3%A3o\) "C (linguagem de programação) – Portuguese") - [Runa Simi](https://qu.wikipedia.org/wiki/C_\(wakichiy_simi\) "C (wakichiy simi) – Quechua") - [Română](https://ro.wikipedia.org/wiki/C_\(limbaj_de_programare\) "C (limbaj de programare) – Romanian") - [Русский](https://ru.wikipedia.org/wiki/%D0%A1%D0%B8_\(%D1%8F%D0%B7%D1%8B%D0%BA_%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D0%BC%D0%B8%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D1%8F\) "Си (язык программирования) – Russian") - [Саха тыла](https://sah.wikipedia.org/wiki/C_\(%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D0%BC%D0%B0%D0%BB%D0%B0%D0%B0h%D1%8B%D0%BD_%D1%82%D1%8B%D0%BB%D0%B0\) "C (программалааhын тыла) – Yakut") - [ᱥᱟᱱᱛᱟᱲᱤ](https://sat.wikipedia.org/wiki/%E1%B1%A5%E1%B1%A4_\(%E1%B1%AF%E1%B1%A8%E1%B1%9A%E1%B1%9C%E1%B1%BD%E1%B1%A8%E1%B1%9F%E1%B1%A2%E1%B1%A4%E1%B1%9D_%E1%B1%AF%E1%B1%9F%E1%B1%B9%E1%B1%A8%E1%B1%A5%E1%B1%A4\) "ᱥᱤ (ᱯᱨᱚᱜᱽᱨᱟᱢᱤᱝ ᱯᱟᱹᱨᱥᱤ) – Santali") - [Scots](https://sco.wikipedia.org/wiki/C_\(programmin_leid\) "C (programmin leid) – Scots") - [Srpskohrvatski / српскохрватски](https://sh.wikipedia.org/wiki/C_\(programski_jezik\) "C (programski jezik) – Serbo-Croatian") - [සිංහල](https://si.wikipedia.org/wiki/C_\(%E0%B6%9A%E0%B7%8A%E2%80%8D%E0%B6%BB%E0%B6%B8%E0%B6%BD%E0%B7%9A%E0%B6%9B%E0%B6%B1_%E0%B6%B7%E0%B7%8F%E0%B7%82%E0%B7%8F%E0%B7%80\) "C (ක්‍රමලේඛන භාෂාව) – Sinhala") - [Simple English](https://simple.wikipedia.org/wiki/C_\(programming_language\) "C (programming language) – Simple English") - [Slovenčina](https://sk.wikipedia.org/wiki/C_\(programovac%C3%AD_jazyk\) "C (programovací jazyk) – Slovak") - [Slovenščina](https://sl.wikipedia.org/wiki/Programski_jezik_C "Programski jezik C – Slovenian") - [Shqip](https://sq.wikipedia.org/wiki/C_\(gjuh%C3%AB_programimi\) "C (gjuhë programimi) – Albanian") - [Српски / srpski](https://sr.wikipedia.org/wiki/C_\(%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D1%81%D0%BA%D0%B8_%D1%98%D0%B5%D0%B7%D0%B8%D0%BA\) "C (програмски језик) – Serbian") - [Svenska](https://sv.wikipedia.org/wiki/C_\(programspr%C3%A5k\) "C (programspråk) – Swedish") - [Kiswahili](https://sw.wikipedia.org/wiki/C_\(lugha_ya_programu\) "C (lugha ya programu) – Swahili") - [தமிழ்](https://ta.wikipedia.org/wiki/%E0%AE%9A%E0%AE%BF_\(%E0%AE%A8%E0%AE%BF%E0%AE%B0%E0%AE%B2%E0%AE%BE%E0%AE%95%E0%AF%8D%E0%AE%95_%E0%AE%AE%E0%AF%8A%E0%AE%B4%E0%AE%BF\) "சி (நிரலாக்க மொழி) – Tamil") - [తెలుగు](https://te.wikipedia.org/wiki/%E0%B0%B8%E0%B0%BF "సి – Telugu") - [Тоҷикӣ](https://tg.wikipedia.org/wiki/C_\(%D0%B7%D0%B0%D0%B1%D0%BE%D0%BD%D0%B8_%D0%B1%D0%B0%D1%80%D0%BD%D0%BE%D0%BC%D0%B0%D1%81%D0%BE%D0%B7%D3%A3\) "C (забони барномасозӣ) – Tajik") - [ไทย](https://th.wikipedia.org/wiki/%E0%B8%A0%E0%B8%B2%E0%B8%A9%E0%B8%B2%E0%B8%8B%E0%B8%B5 "ภาษาซี – Thai") - [Tagalog](https://tl.wikipedia.org/wiki/C_\(wikang_pamprograma\) "C (wikang pamprograma) – Tagalog") - [Toki pona](https://tok.wikipedia.org/wiki/toki_ilo_Si "toki ilo Si – Toki Pona") - [Türkçe](https://tr.wikipedia.org/wiki/C_\(programlama_dili\) "C (programlama dili) – Turkish") - [Татарча / tatarça](https://tt.wikipedia.org/wiki/%D0%A1%D0%B8_\(%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D0%BC%D0%B0%D0%BB%D0%B0%D1%83_%D1%82%D0%B5%D0%BB%D0%B5\) "Си (программалау теле) – Tatar") - [ChiTumbuka](https://tum.wikipedia.org/wiki/C_\(chiyowoyero_cha_mapulogalamu\) "C (chiyowoyero cha mapulogalamu) – Tumbuka") - [Українська](https://uk.wikipedia.org/wiki/C_\(%D0%BC%D0%BE%D0%B2%D0%B0_%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D1%83%D0%B2%D0%B0%D0%BD%D0%BD%D1%8F\) "C (мова програмування) – Ukrainian") - [اردو](https://ur.wikipedia.org/wiki/%D8%B3%DB%8C_\(%D9%BE%D8%B1%D9%88%DA%AF%D8%B1%D8%A7%D9%85%D9%86%DA%AF_%D8%B2%D8%A8%D8%A7%D9%86\) "سی (پروگرامنگ زبان) – Urdu") - [Oʻzbekcha / ўзбекча](https://uz.wikipedia.org/wiki/C_\(dasturlash_tili\) "C (dasturlash tili) – Uzbek") - [Vèneto](https://vec.wikipedia.org/wiki/Lenguajo_C "Lenguajo C – Venetian") - [Tiếng Việt](https://vi.wikipedia.org/wiki/C_\(ng%C3%B4n_ng%E1%BB%AF_l%E1%BA%ADp_tr%C3%ACnh\) "C (ngôn ngữ lập trình) – Vietnamese") - [Winaray](https://war.wikipedia.org/wiki/C_\(linggwahe_hin_pagprograma\) "C (linggwahe hin pagprograma) – Waray") - [吴语](https://wuu.wikipedia.org/wiki/C%E8%AF%AD%E8%A8%80 "C语言 – Wu") - [IsiXhosa](https://xh.wikipedia.org/wiki/U-C_\(woku-programa_ulwimi\) "U-C (woku-programa ulwimi) – Xhosa") - [ייִדיש](https://yi.wikipedia.org/wiki/C_\(%D7%A4%D7%A8%D7%90%D7%92%D7%A8%D7%90%D7%9D_%D7%A9%D7%A4%D7%A8%D7%90%D7%9A\) "C (פראגראם שפראך) – Yiddish") - [ⵜⴰⵎⴰⵣⵉⵖⵜ ⵜⴰⵏⴰⵡⴰⵢⵜ](https://zgh.wikipedia.org/wiki/%E2%B5%99%E2%B5%89_\(%E2%B5%9C%E2%B5%93%E2%B5%9C%E2%B5%8D%E2%B4%B0%E2%B5%A2%E2%B5%9C_%E2%B5%8F_%E2%B5%93%E2%B5%99%E2%B5%96%E2%B5%89%E2%B5%A1%E2%B5%99\) "ⵙⵉ (ⵜⵓⵜⵍⴰⵢⵜ ⵏ ⵓⵙⵖⵉⵡⵙ) – Standard Moroccan Tamazight") - [文言](https://zh-classical.wikipedia.org/wiki/%E4%B8%99%E8%AA%9E "丙語 – Literary Chinese") - [閩南語 / Bân-lâm-gí](https://zh-min-nan.wikipedia.org/wiki/C_\(th%C3%AAng-sek_g%C3%AD-gi%C3%A2n\) "C (thêng-sek gí-giân) – Minnan") - [粵語](https://zh-yue.wikipedia.org/wiki/C_\(%E7%A8%8B%E5%BC%8F%E8%AA%9E%E8%A8%80\) "C (程式語言) – Cantonese") - [中文](https://zh.wikipedia.org/wiki/C%E8%AF%AD%E8%A8%80 "C语言 – Chinese") [Edit links](https://www.wikidata.org/wiki/Special:EntityPage/Q15777#sitelinks-wikipedia "Edit interlanguage links") - [Article](https://en.wikipedia.org/wiki/C_\(programming_language\) "View the content page [c]") - [Talk](https://en.wikipedia.org/wiki/Talk:C_\(programming_language\) "Discuss improvements to the content page [t]") English - [Read](https://en.wikipedia.org/wiki/C_\(programming_language\)) - [Edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit "Edit this page [e]") - [View history](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=history "Past revisions of this page [h]") Tools Tools move to sidebar hide Actions - [Read](https://en.wikipedia.org/wiki/C_\(programming_language\)) - [Edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit "Edit this page [e]") - [View history](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=history) General - [What links here](https://en.wikipedia.org/wiki/Special:WhatLinksHere/C_\(programming_language\) "List of all English Wikipedia pages containing links to this page [j]") - [Related changes](https://en.wikipedia.org/wiki/Special:RecentChangesLinked/C_\(programming_language\) "Recent changes in pages linked from this page [k]") - [Upload file](https://en.wikipedia.org/wiki/Wikipedia:File_Upload_Wizard "Upload files [u]") - [Permanent link](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&oldid=1345046563 "Permanent link to this revision of this page") - [Page information](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=info "More information about this page") - [Cite this page](https://en.wikipedia.org/w/index.php?title=Special:CiteThisPage&page=C_%28programming_language%29&id=1345046563&wpFormIdentifier=titleform "Information on how to cite this page") - [Get shortened URL](https://en.wikipedia.org/w/index.php?title=Special:UrlShortener&url=https%3A%2F%2Fen.wikipedia.org%2Fwiki%2FC_%28programming_language%29) Print/export - [Download as PDF](https://en.wikipedia.org/w/index.php?title=Special:DownloadAsPdf&page=C_%28programming_language%29&action=show-download-screen "Download this page as a PDF file") - [Printable version](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&printable=yes "Printable version of this page [p]") In other projects - [Wikimedia Commons](https://commons.wikimedia.org/wiki/Category:C_\(programming_language\)) - [Wikibooks](https://en.wikibooks.org/wiki/C_Programming) - [Wikiquote](https://en.wikiquote.org/wiki/C_\(programming_language\)) - [Wikiversity](https://en.wikiversity.org/wiki/C_Programming) - [Wikidata item](https://www.wikidata.org/wiki/Special:EntityPage/Q15777 "Structured data on this page hosted by Wikidata [g]") Appearance move to sidebar hide **Checked** [![Page protected with pending changes](https://upload.wikimedia.org/wikipedia/en/thumb/b/b7/Pending-protection-shackle.svg/20px-Pending-protection-shackle.svg.png)](https://en.wikipedia.org/wiki/Wikipedia:Protection_policy#pending "All edits by unregistered and new users are subject to review prior to becoming visible to unregistered users") From Wikipedia, the free encyclopedia ## Page version status This is an accepted version of this page This is the [latest accepted revision](https://en.wikipedia.org/wiki/Wikipedia:Pending_changes "Wikipedia:Pending changes"), [reviewed](https://en.wikipedia.org/w/index.php?title=Special:Log&type=review&page=C_\(programming_language\)) on *24 March 2026*. General-purpose programming language "C programming language" redirects here. For the book, see [*The C Programming Language*](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language"). "C lang" redirects here. For the compiler front end, see [Clang](https://en.wikipedia.org/wiki/Clang "Clang"). Not to be confused with [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") or [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)"). | C | | |---|---| | [![](https://upload.wikimedia.org/wikipedia/commons/thumb/3/35/The_C_Programming_Language_logo.svg/250px-The_C_Programming_Language_logo.svg.png)](https://en.wikipedia.org/wiki/File:The_C_Programming_Language_logo.svg)Logotype used on the cover of the first edition of *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*[\[1\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-C_in_a_Nutshell-1) | | | [Paradigm](https://en.wikipedia.org/wiki/Programming_paradigm "Programming paradigm") | [Multi-paradigm](https://en.wikipedia.org/wiki/Multi-paradigm "Multi-paradigm"): [imperative](https://en.wikipedia.org/wiki/Imperative_programming "Imperative programming") ([procedural](https://en.wikipedia.org/wiki/Procedural_programming "Procedural programming")), [structured](https://en.wikipedia.org/wiki/Structured_programming "Structured programming") | | [Designed by](https://en.wikipedia.org/wiki/Software_design "Software design") | [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") | | [Developer](https://en.wikipedia.org/wiki/Software_developer "Software developer") | ANSI X3J11 ([ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C")); [ISO/IEC JTC 1 (Joint Technical Committee 1) / SC 22 (Subcommittee 22)](https://en.wikipedia.org/wiki/ISO/IEC_JTC_1/SC_22 "ISO/IEC JTC 1/SC 22") / WG 14 (Working Group 14) (ISO C) | | First appeared | 1972; 54 years ago (1972)[\[a\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-5) | | [Stable release](https://en.wikipedia.org/wiki/Software_release_life_cycle "Software release life cycle") | [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)") / October 31, 2024; 17 months ago (2024-10-31) | | [Preview release](https://en.wikipedia.org/wiki/Software_release_life_cycle#Beta "Software release life cycle") | [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") (N3220) / February 21, 2024; 2 years ago (2024-02-21)[\[5\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-6) | | [Typing discipline](https://en.wikipedia.org/wiki/Type_system "Type system") | [Static](https://en.wikipedia.org/wiki/Type_system "Type system"), [weak](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"), [manifest](https://en.wikipedia.org/wiki/Manifest_typing "Manifest typing"), [nominal](https://en.wikipedia.org/wiki/Nominal_type_system "Nominal type system") | | [OS](https://en.wikipedia.org/wiki/Operating_system "Operating system") | [Cross-platform](https://en.wikipedia.org/wiki/Cross-platform "Cross-platform") | | [Filename extensions](https://en.wikipedia.org/wiki/Filename_extension "Filename extension") | .c, .h | | Website | [c-language.org](https://www.c-language.org/) [iso.org](https://www.iso.org/standard/82075.html) [open-std.org](https://www.open-std.org/jtc1/sc22/wg14/) | | Major [implementations](https://en.wikipedia.org/wiki/Programming_language_implementation "Programming language implementation") | | | [pcc](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler"), [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection"), [Clang](https://en.wikipedia.org/wiki/Clang "Clang"), [Intel C](https://en.wikipedia.org/wiki/Intel_C%2B%2B_Compiler "Intel C++ Compiler"), [C++Builder](https://en.wikipedia.org/wiki/C%2B%2BBuilder "C++Builder"), [Microsoft Visual C++](https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B "Microsoft Visual C++"), [Watcom C](https://en.wikipedia.org/wiki/Watcom_C/C%2B%2B "Watcom C/C++") | | | [Dialects](https://en.wikipedia.org/wiki/Programming_language#Dialects,_flavors_and_implementations "Programming language") | | | [Cyclone](https://en.wikipedia.org/wiki/Cyclone_\(programming_language\) "Cyclone (programming language)"), [Unified Parallel C](https://en.wikipedia.org/wiki/Unified_Parallel_C "Unified Parallel C"), [Split-C](https://en.wikipedia.org/wiki/Split-C "Split-C"), [Cilk](https://en.wikipedia.org/wiki/Cilk "Cilk"), [C\*](https://en.wikipedia.org/wiki/C* "C*") | | | Influenced by | | | [B](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)"), [BCPL](https://en.wikipedia.org/wiki/BCPL "BCPL"), [CPL](https://en.wikipedia.org/wiki/CPL_\(programming_language\) "CPL (programming language)"), [ALGOL 68](https://en.wikipedia.org/wiki/ALGOL_68 "ALGOL 68"),[\[b\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-9) [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I"), [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") | | | Influenced | | | [Numerous](https://en.wikipedia.org/wiki/Category:C_programming_language_family "Category:C programming language family"): [AMPL](https://en.wikipedia.org/wiki/AMPL "AMPL"), [AWK](https://en.wikipedia.org/wiki/AWK "AWK"), [csh](https://en.wikipedia.org/wiki/C_shell "C shell"), [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++"), [C--](https://en.wikipedia.org/wiki/C-- "C--"), [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)"), [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C"), [D](https://en.wikipedia.org/wiki/D_\(programming_language\) "D (programming language)"), [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)"), [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)"), [JavaScript](https://en.wikipedia.org/wiki/JavaScript "JavaScript"), [JS++](https://en.wikipedia.org/wiki/JS%2B%2B "JS++"), [Julia](https://en.wikipedia.org/wiki/Julia_\(programming_language\) "Julia (programming language)"), [Limbo](https://en.wikipedia.org/wiki/Limbo_\(programming_language\) "Limbo (programming language)"), [LPC](https://en.wikipedia.org/wiki/LPC_\(programming_language\) "LPC (programming language)"), [Perl](https://en.wikipedia.org/wiki/Perl "Perl"), [PHP](https://en.wikipedia.org/wiki/PHP "PHP"), [Pike](https://en.wikipedia.org/wiki/Pike_\(programming_language\) "Pike (programming language)"), [Processing](https://en.wikipedia.org/wiki/Processing_\(programming_language\) "Processing (programming language)"), [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)"), [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)"), [V (Vlang)](https://en.wikipedia.org/wiki/V_\(programming_language\) "V (programming language)"), [Vala](https://en.wikipedia.org/wiki/Vala_\(programming_language\) "Vala (programming language)"), [Verilog](https://en.wikipedia.org/wiki/Verilog "Verilog") (HDL),[\[8\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-vinsp-10) [Nim](https://en.wikipedia.org/wiki/Nim_\(programming_language\) "Nim (programming language)"), [Zig](https://en.wikipedia.org/wiki/Zig_\(programming_language\) "Zig (programming language)") | | | [![Wikibooks logo](https://upload.wikimedia.org/wikipedia/commons/thumb/f/fa/Wikibooks-logo.svg/20px-Wikibooks-logo.svg.png)](https://en.wikipedia.org/wiki/File:Wikibooks-logo.svg) [C Programming](https://en.wikibooks.org/wiki/C_Programming "wikibooks:C Programming") at Wikibooks | | | | |---| | This article is part of [a series](https://en.wikipedia.org/wiki/Category:C_\(programming_language\) "Category:C (programming language)") on the [C programming language](https://en.wikipedia.org/wiki/C_programming_language "C programming language") | | [![The logo of C programming language](https://upload.wikimedia.org/wikipedia/commons/thumb/3/35/The_C_Programming_Language_logo.svg/60px-The_C_Programming_Language_logo.svg.png)](https://en.wikipedia.org/wiki/C_\(programming_language\) "The logo of C programming language") | | [C libraries and tools](https://en.wikipedia.org/wiki/List_of_C_software_and_tools#Libraries_and_tools "List of C software and tools") [Adns](https://en.wikipedia.org/wiki/Adns "Adns") [ALSA](https://en.wikipedia.org/wiki/Advanced_Linux_Sound_Architecture "Advanced Linux Sound Architecture") [Allegro](https://en.wikipedia.org/wiki/Allegro_\(software_library\) "Allegro (software library)") [APR](https://en.wikipedia.org/wiki/Apache_Portable_Runtime "Apache Portable Runtime") [Argon2](https://en.wikipedia.org/wiki/Argon2 "Argon2") [Assimp](https://en.wikipedia.org/wiki/Assimp "Assimp") [bdwgc](https://en.wikipedia.org/wiki/Boehm_garbage_collector "Boehm garbage collector") [Berkeley DB](https://en.wikipedia.org/wiki/Berkeley_DB "Berkeley DB") [BFD](https://en.wikipedia.org/wiki/Binary_File_Descriptor_library "Binary File Descriptor library") [BGI](https://en.wikipedia.org/wiki/Borland_Graphics_Interface "Borland Graphics Interface") [BSAFE](https://en.wikipedia.org/wiki/BSAFE "BSAFE") [Chipmunk](https://en.wikipedia.org/wiki/Chipmunk_\(physics_engine\) "Chipmunk (physics engine)") [C POSIX library](https://en.wikipedia.org/wiki/C_POSIX_library "C POSIX library") [C standard library](https://en.wikipedia.org/wiki/C_standard_library "C standard library") [Cairo](https://en.wikipedia.org/wiki/Cairo_\(graphics\) "Cairo (graphics)") [CGNS](https://en.wikipedia.org/wiki/CGNS "CGNS") [CLIPS](https://en.wikipedia.org/wiki/CLIPS "CLIPS") [Core Audio](https://en.wikipedia.org/wiki/Core_Audio "Core Audio") [Core Foundation](https://en.wikipedia.org/wiki/Core_Foundation "Core Foundation") [Core Image](https://en.wikipedia.org/wiki/Core_Image "Core Image") [Core Text](https://en.wikipedia.org/wiki/Core_Text "Core Text") [Cryptlib](https://en.wikipedia.org/wiki/Cryptlib "Cryptlib") [cURL](https://en.wikipedia.org/wiki/CURL "CURL") [DevIL](https://en.wikipedia.org/wiki/DevIL "DevIL") [DirectFB](https://en.wikipedia.org/wiki/DirectFB "DirectFB") [Dld](https://en.wikipedia.org/wiki/Dld_\(software\) "Dld (software)") [Expat](https://en.wikipedia.org/wiki/Expat_\(software\) "Expat (software)") [FFmpeg](https://en.wikipedia.org/wiki/FFmpeg "FFmpeg") [Fontconfig](https://en.wikipedia.org/wiki/Fontconfig "Fontconfig") [FreeTDS](https://en.wikipedia.org/wiki/FreeTDS "FreeTDS") [FreeType](https://en.wikipedia.org/wiki/FreeType "FreeType") [GD Graphics Library](https://en.wikipedia.org/wiki/GD_Graphics_Library "GD Graphics Library") [GDK](https://en.wikipedia.org/wiki/GDK "GDK") [GEGL](https://en.wikipedia.org/wiki/GEGL "GEGL") [GGI](https://en.wikipedia.org/wiki/General_Graphics_Interface "General Graphics Interface") [GIO](https://en.wikipedia.org/wiki/GIO_\(software\) "GIO (software)") [GLib](https://en.wikipedia.org/wiki/GLib "GLib") [glibc](https://en.wikipedia.org/wiki/GNU_C_Library "GNU C Library") [GLFW](https://en.wikipedia.org/wiki/GLFW "GLFW") [GNet](https://en.wikipedia.org/wiki/GNet "GNet") [GNU Libtool](https://en.wikipedia.org/wiki/GNU_Libtool "GNU Libtool") [GNU portability library](https://en.wikipedia.org/wiki/GNU_portability_library "GNU portability library") [GNU Portable Threads](https://en.wikipedia.org/wiki/GNU_Portable_Threads "GNU Portable Threads") [GNU Readline](https://en.wikipedia.org/wiki/GNU_Readline "GNU Readline") [GnuTLS](https://en.wikipedia.org/wiki/GnuTLS "GnuTLS") [GObject](https://en.wikipedia.org/wiki/GObject "GObject") [GTK Scene Graph Kit](https://en.wikipedia.org/wiki/GTK_Scene_Graph_Kit "GTK Scene Graph Kit") [GTK](https://en.wikipedia.org/wiki/GTK "GTK") [HDF](https://en.wikipedia.org/wiki/Hierarchical_Data_Format "Hierarchical Data Format") [Intel IPP](https://en.wikipedia.org/wiki/Integrated_Performance_Primitives "Integrated Performance Primitives") [IUP](https://en.wikipedia.org/wiki/IUP_\(software\) "IUP (software)") [J2K-Codec](https://en.wikipedia.org/wiki/J2K-Codec "J2K-Codec") [JasPer](https://en.wikipedia.org/wiki/JasPer "JasPer") [LDAP API](https://en.wikipedia.org/wiki/LDAP_Application_Program_Interface "LDAP Application Program Interface") [LZO](https://en.wikipedia.org/wiki/Lempel%E2%80%93Ziv%E2%80%93Oberhumer "Lempel–Ziv–Oberhumer") [Liba52](https://en.wikipedia.org/wiki/Liba52 "Liba52") [Libaf](https://en.wikipedia.org/wiki/Libaf "Libaf") [Libao2](https://en.wikipedia.org/wiki/Libao2 "Libao2") [libarchive](https://en.wikipedia.org/wiki/Libarchive "Libarchive") [Libart](https://en.wikipedia.org/wiki/Libart "Libart") [Libass](https://en.wikipedia.org/wiki/Libass "Libass") [Libavcodec](https://en.wikipedia.org/wiki/Libavcodec "Libavcodec") [Libavdevice](https://en.wikipedia.org/wiki/Libavdevice "Libavdevice") [Libavfilter](https://en.wikipedia.org/wiki/Libavfilter "Libavfilter") [Libavformat](https://en.wikipedia.org/wiki/Libavformat "Libavformat") [Libpcap](https://en.wikipedia.org/wiki/Libpcap "Libpcap") [Libdca](https://en.wikipedia.org/wiki/Libdca "Libdca") [Libdvdcss](https://en.wikipedia.org/wiki/Libdvdcss "Libdvdcss") [libevent](https://en.wikipedia.org/wiki/Libevent "Libevent") [libffi](https://en.wikipedia.org/wiki/Libffi "Libffi") [Libgegl](https://en.wikipedia.org/wiki/Libgegl "Libgegl") [libgcrypt](https://en.wikipedia.org/wiki/Libgcrypt "Libgcrypt") [Libgimp](https://en.wikipedia.org/wiki/Libgimp "Libgimp") [Libhybris](https://en.wikipedia.org/wiki/Libhybris "Libhybris") [Libinput](https://en.wikipedia.org/wiki/Libinput "Libinput") [libjpeg](https://en.wikipedia.org/wiki/Libjpeg "Libjpeg") [libLAS](https://en.wikipedia.org/wiki/LibLAS "LibLAS") [Libmpcodecs](https://en.wikipedia.org/wiki/Libmpcodecs "Libmpcodecs") [Libmpdemux](https://en.wikipedia.org/wiki/Libmpdemux "Libmpdemux") [libpng](https://en.wikipedia.org/wiki/Libpng "Libpng") [Libpostproc](https://en.wikipedia.org/wiki/Libpostproc "Libpostproc") [libpq](https://en.wikipedia.org/wiki/Libpq "Libpq") [LibreSSL](https://en.wikipedia.org/wiki/LibreSSL "LibreSSL") [Librsb](https://en.wikipedia.org/wiki/Librsb "Librsb") [Librsvg](https://en.wikipedia.org/wiki/Librsvg "Librsvg") [libsndfile](https://en.wikipedia.org/wiki/Libsndfile "Libsndfile") [libsodium](https://en.wikipedia.org/wiki/Libsodium "Libsodium") [Libswscale](https://en.wikipedia.org/wiki/Libswscale "Libswscale") [LibTIFF](https://en.wikipedia.org/wiki/LibTIFF "LibTIFF") [Libusb](https://en.wikipedia.org/wiki/Libusb "Libusb") [libuv](https://en.wikipedia.org/wiki/Libuv "Libuv") [LibVLC](https://en.wikipedia.org/wiki/VLC_media_player#Use_of_VLC_with_other_programs "VLC media player") [LibVNCServer](https://en.wikipedia.org/wiki/LibVNCServer "LibVNCServer") [Libvpx](https://en.wikipedia.org/wiki/Libvpx "Libvpx") [Libwww](https://en.wikipedia.org/wiki/Libwww "Libwww") [libxml2](https://en.wikipedia.org/wiki/Libxml2 "Libxml2") [Libxslt](https://en.wikipedia.org/wiki/Libxslt "Libxslt") [libzip](https://en.wikipedia.org/wiki/Libzip "Libzip") [LMDB](https://en.wikipedia.org/wiki/Lightning_Memory-Mapped_Database "Lightning Memory-Mapped Database") [LittleCMS](https://en.wikipedia.org/wiki/LittleCMS "LittleCMS") [LZ4](https://en.wikipedia.org/wiki/LZ4_\(compression_algorithm\) "LZ4 (compression algorithm)") [LZFSE](https://en.wikipedia.org/wiki/LZFSE "LZFSE") [MatrixSSL](https://en.wikipedia.org/wiki/MatrixSSL "MatrixSSL") [Mbed TLS](https://en.wikipedia.org/wiki/Mbed_TLS "Mbed TLS") [MediaLib](https://en.wikipedia.org/wiki/MediaLib "MediaLib") [Mesa](https://en.wikipedia.org/wiki/Mesa_\(computer_graphics\) "Mesa (computer graphics)") [Microwindows](https://en.wikipedia.org/wiki/Microwindows "Microwindows") [Ming](https://en.wikipedia.org/wiki/Ming_library "Ming library") [Mongoose](https://en.wikipedia.org/wiki/Mongoose_\(web_server\) "Mongoose (web server)") [Mpg123](https://en.wikipedia.org/wiki/Mpg123 "Mpg123") [MPIR](https://en.wikipedia.org/wiki/MPIR_\(mathematics_software\) "MPIR (mathematics software)") [MsQuic](https://en.wikipedia.org/wiki/MsQuic "MsQuic") [MuJoCo](https://en.wikipedia.org/wiki/MuJoCo "MuJoCo") [Mustache](https://en.wikipedia.org/wiki/Mustache_\(template_system\) "Mustache (template system)") [Ncurses](https://en.wikipedia.org/wiki/Ncurses "Ncurses") [Nettle](https://en.wikipedia.org/wiki/Nettle_\(cryptographic_library\) "Nettle (cryptographic library)") [Newt](https://en.wikipedia.org/wiki/Newt_\(programming_library\) "Newt (programming library)") [Netpbm](https://en.wikipedia.org/wiki/Netpbm "Netpbm") [Nghttp2](https://en.wikipedia.org/wiki/Nghttp2 "Nghttp2") [Nrrd](https://en.wikipedia.org/wiki/Nrrd "Nrrd") [Oniguruma](https://en.wikipedia.org/wiki/Oniguruma "Oniguruma") [OpenCL](https://en.wikipedia.org/wiki/OpenCL "OpenCL") [OpenCV](https://en.wikipedia.org/wiki/OpenCV "OpenCV") [OpenGL](https://en.wikipedia.org/wiki/OpenGL "OpenGL") [OpenGL Utility Library](https://en.wikipedia.org/wiki/OpenGL_Utility_Library "OpenGL Utility Library") [OpenJPEG](https://en.wikipedia.org/wiki/OpenJPEG "OpenJPEG") [OpenSSL](https://en.wikipedia.org/wiki/OpenSSL "OpenSSL") [Pango](https://en.wikipedia.org/wiki/Pango "Pango") [PCRE](https://en.wikipedia.org/wiki/PCRE "PCRE") [PROJ](https://en.wikipedia.org/wiki/PROJ "PROJ") [Quartz 2D](https://en.wikipedia.org/wiki/Quartz_2D "Quartz 2D") [Raylib](https://en.wikipedia.org/wiki/Raylib "Raylib") [Redland RDF](https://en.wikipedia.org/wiki/Redland_RDF_Application_Framework "Redland RDF Application Framework") [S2n-tls](https://en.wikipedia.org/wiki/S2n-tls "S2n-tls") [Setcontext](https://en.wikipedia.org/wiki/Setcontext "Setcontext") [SFML](https://en.wikipedia.org/wiki/SFML "SFML") [SDL](https://en.wikipedia.org/wiki/Simple_DirectMedia_Layer "Simple DirectMedia Layer") [SQLite](https://en.wikipedia.org/wiki/SQLite "SQLite") [systemd](https://en.wikipedia.org/wiki/Systemd "Systemd") [Tk](https://en.wikipedia.org/wiki/Tk_\(software\) "Tk (software)") [VDPAU](https://en.wikipedia.org/wiki/VDPAU "VDPAU") [Vorbis](https://en.wikipedia.org/wiki/Vorbis "Vorbis") [VTD-XML](https://en.wikipedia.org/wiki/VTD-XML "VTD-XML") [Win32 API](https://en.wikipedia.org/wiki/Win32_API "Win32 API") [Wimlib](https://en.wikipedia.org/wiki/Wimlib "Wimlib") [Windows.h](https://en.wikipedia.org/wiki/Windows.h "Windows.h") [WolfSSH](https://en.wikipedia.org/wiki/WolfSSH "WolfSSH") [WolfSSL](https://en.wikipedia.org/wiki/WolfSSL "WolfSSL") [X Toolkit Intrinsics](https://en.wikipedia.org/wiki/X_Toolkit_Intrinsics "X Toolkit Intrinsics") [x264](https://en.wikipedia.org/wiki/X264 "X264") [XCB](https://en.wikipedia.org/wiki/XCB "XCB") [Xft](https://en.wikipedia.org/wiki/Xft "Xft") [Xlib](https://en.wikipedia.org/wiki/Xlib "Xlib") [XMDF](https://en.wikipedia.org/wiki/XMDF "XMDF") [XMLStarlet](https://en.wikipedia.org/wiki/XMLStarlet "XMLStarlet") [zlib](https://en.wikipedia.org/wiki/Zlib "Zlib") [Zopfli](https://en.wikipedia.org/wiki/Zopfli "Zopfli") [Zstd](https://en.wikipedia.org/wiki/Zstd "Zstd") | | [C IDEs](https://en.wikipedia.org/wiki/Comparison_of_integrated_development_environments#C/C++ "Comparison of integrated development environments") [Anjuta](https://en.wikipedia.org/wiki/Anjuta "Anjuta") [AppCode](https://en.wikipedia.org/wiki/AppCode "AppCode") [C++Builder](https://en.wikipedia.org/wiki/C%2B%2BBuilder "C++Builder") [CLion](https://en.wikipedia.org/wiki/CLion "CLion") [Code::Blocks](https://en.wikipedia.org/wiki/Code::Blocks "Code::Blocks") [CodeLite](https://en.wikipedia.org/wiki/CodeLite "CodeLite") [Dev-C++](https://en.wikipedia.org/wiki/Dev-C%2B%2B "Dev-C++") [Eclipse CDT](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)") [Geany](https://en.wikipedia.org/wiki/Geany "Geany") [KDevelop](https://en.wikipedia.org/wiki/KDevelop "KDevelop") [LabWindows/CVI](https://en.wikipedia.org/wiki/LabWindows/CVI "LabWindows/CVI") [Microsoft Visual Studio](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio "Microsoft Visual Studio") [MonoDevelop](https://en.wikipedia.org/wiki/MonoDevelop "MonoDevelop") [NetBeans IDE](https://en.wikipedia.org/wiki/NetBeans_IDE "NetBeans IDE") [OpenWatcom](https://en.wikipedia.org/wiki/OpenWatcom "OpenWatcom") [Oracle Solaris Studio](https://en.wikipedia.org/wiki/Oracle_Solaris_Studio "Oracle Solaris Studio") [Pelles C IDE](https://en.wikipedia.org/wiki/LCC_\(compiler\) "LCC (compiler)") [Qt Creator](https://en.wikipedia.org/wiki/Qt_Creator "Qt Creator") [SlickEdit](https://en.wikipedia.org/wiki/SlickEdit "SlickEdit") [Ultimate++](https://en.wikipedia.org/wiki/Ultimate%2B%2B "Ultimate++") [Understand](https://en.wikipedia.org/wiki/Understand_\(software\) "Understand (software)") [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") [Xcode](https://en.wikipedia.org/wiki/Xcode "Xcode") | | [C compilers](https://en.wikipedia.org/wiki/List_of_C_compilers "List of C compilers") [Acorn C/C++](https://en.wikipedia.org/wiki/Acorn_C/C%2B%2B "Acorn C/C++") [AMD Optimizing C/C++ Compiler](https://en.wikipedia.org/wiki/AMD_Optimizing_C/C%2B%2B_Compiler "AMD Optimizing C/C++ Compiler") [Amsterdam Compiler Kit](https://en.wikipedia.org/wiki/Amsterdam_Compiler_Kit "Amsterdam Compiler Kit") [Aztec C](https://en.wikipedia.org/wiki/Aztec_C "Aztec C") [BDS C](https://en.wikipedia.org/wiki/BDS_C "BDS C") [Cc65](https://en.wikipedia.org/wiki/Cc65 "Cc65") [Ccache](https://en.wikipedia.org/wiki/Ccache "Ccache") [Clang](https://en.wikipedia.org/wiki/Clang "Clang") [CodeWarrior](https://en.wikipedia.org/wiki/CodeWarrior "CodeWarrior") [Comeau C/C++](https://en.wikipedia.org/wiki/Comeau_C/C%2B%2B "Comeau C/C++") [C++Builder](https://en.wikipedia.org/wiki/C%2B%2BBuilder "C++Builder") [Csmith](https://en.wikipedia.org/wiki/Csmith "Csmith") [Deep Blue C](https://en.wikipedia.org/wiki/Deep_Blue_C "Deep Blue C") [Digital Mars](https://en.wikipedia.org/wiki/Digital_Mars "Digital Mars") [DJGPP](https://en.wikipedia.org/wiki/DJGPP "DJGPP") [FpgaC](https://en.wikipedia.org/wiki/FpgaC "FpgaC") [GNU Compiler Collection](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection") [HP aC++](https://en.wikipedia.org/wiki/HP_aC%2B%2B "HP aC++") [IBM XL C/C++ Compilers](https://en.wikipedia.org/wiki/IBM_XL_C/C%2B%2B_Compilers "IBM XL C/C++ Compilers") [Intel C++ Compiler](https://en.wikipedia.org/wiki/Intel_C%2B%2B_Compiler "Intel C++ Compiler") [LabWindows/CVI](https://en.wikipedia.org/wiki/LabWindows/CVI "LabWindows/CVI") [Lattice C](https://en.wikipedia.org/wiki/Lattice_C "Lattice C") [LCC](https://en.wikipedia.org/wiki/LCC_\(compiler\) "LCC (compiler)") [Macintosh Programmer's Workshop](https://en.wikipedia.org/wiki/Macintosh_Programmer%27s_Workshop "Macintosh Programmer's Workshop") [Megamax C](https://en.wikipedia.org/wiki/Megamax_C "Megamax C") [Microsoft Visual C++](https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B "Microsoft Visual C++") [MinGW](https://en.wikipedia.org/wiki/MinGW "MinGW") [Mingw-w64](https://en.wikipedia.org/wiki/Mingw-w64 "Mingw-w64") [Norcroft C compiler](https://en.wikipedia.org/wiki/Norcroft_C_compiler "Norcroft C compiler") [Open64](https://en.wikipedia.org/wiki/Open64 "Open64") [Oracle Developer Studio](https://en.wikipedia.org/wiki/Oracle_Developer_Studio "Oracle Developer Studio") [PathScale](https://en.wikipedia.org/wiki/PathScale "PathScale") [Portable C Compiler](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler") [The Portland Group](https://en.wikipedia.org/wiki/The_Portland_Group "The Portland Group") [QuickC](https://en.wikipedia.org/wiki/QuickC "QuickC") [ROSE](https://en.wikipedia.org/wiki/ROSE_\(compiler_framework\) "ROSE (compiler framework)") [SAS/C](https://en.wikipedia.org/wiki/SAS/C "SAS/C") [Small Device C Compiler](https://en.wikipedia.org/wiki/Small_Device_C_Compiler "Small Device C Compiler") [Small-C](https://en.wikipedia.org/wiki/Small-C "Small-C") [TDM-GCC](https://en.wikipedia.org/wiki/TDM-GCC "TDM-GCC") [TenDRA Compiler](https://en.wikipedia.org/wiki/TenDRA_Compiler "TenDRA Compiler") [THINK C](https://en.wikipedia.org/wiki/THINK_C "THINK C") [Tiny C Compiler](https://en.wikipedia.org/wiki/Tiny_C_Compiler "Tiny C Compiler") [Turbo C](https://en.wikipedia.org/wiki/Turbo_C "Turbo C") [Vbcc](https://en.wikipedia.org/wiki/Vbcc "Vbcc") [VisualAge](https://en.wikipedia.org/wiki/VisualAge "VisualAge") [Watcom C/C++](https://en.wikipedia.org/wiki/Watcom_C/C%2B%2B "Watcom C/C++") [Whitesmiths](https://en.wikipedia.org/wiki/Whitesmiths "Whitesmiths") [Z88DK](https://en.wikipedia.org/wiki/Z88DK "Z88DK") [Zig](https://en.wikipedia.org/wiki/Zig_\(programming_language\) "Zig (programming language)") | | [C mathematical libraries](https://en.wikipedia.org/wiki/List_of_C_software_and_tools#Mathematical_libraries "List of C software and tools") [Automatically Tuned Linear Algebra Software](https://en.wikipedia.org/wiki/Automatically_Tuned_Linear_Algebra_Software "Automatically Tuned Linear Algebra Software") [Basic Linear Algebra Subprograms](https://en.wikipedia.org/wiki/Basic_Linear_Algebra_Subprograms "Basic Linear Algebra Subprograms") [BLOPEX](https://en.wikipedia.org/wiki/BLOPEX "BLOPEX") [C mathematical functions](https://en.wikipedia.org/wiki/C_mathematical_functions "C mathematical functions") [Fastest Fourier Transform in the West](https://en.wikipedia.org/wiki/Fastest_Fourier_Transform_in_the_West "Fastest Fourier Transform in the West") [GNU MPFR](https://en.wikipedia.org/wiki/GNU_MPFR "GNU MPFR") [GNU Multiple Precision Arithmetic Library](https://en.wikipedia.org/wiki/GNU_Multiple_Precision_Arithmetic_Library "GNU Multiple Precision Arithmetic Library") [GNU Scientific Library](https://en.wikipedia.org/wiki/GNU_Scientific_Library "GNU Scientific Library") [hypre](https://en.wikipedia.org/wiki/Hypre "Hypre") [Integer set library](https://en.wikipedia.org/wiki/Integer_set_library "Integer set library") [LAPACK](https://en.wikipedia.org/wiki/LAPACK "LAPACK") [Libfixmath](https://en.wikipedia.org/wiki/Libfixmath "Libfixmath") [Lis (linear algebra library)](https://en.wikipedia.org/wiki/Lis_\(linear_algebra_library\) "Lis (linear algebra library)") [LOBPCG](https://en.wikipedia.org/wiki/LOBPCG "LOBPCG") [Math Kernel Library](https://en.wikipedia.org/wiki/Math_Kernel_Library "Math Kernel Library") [Mathomatic](https://en.wikipedia.org/wiki/Mathomatic "Mathomatic") [OpenBLAS](https://en.wikipedia.org/wiki/OpenBLAS "OpenBLAS") [PARI/GP](https://en.wikipedia.org/wiki/PARI/GP "PARI/GP") [ScaLAPACK](https://en.wikipedia.org/wiki/ScaLAPACK "ScaLAPACK") [PETSc](https://en.wikipedia.org/wiki/PETSc "PETSc") [SLEPc](https://en.wikipedia.org/wiki/SLEPc "SLEPc") [UMFPACK](https://en.wikipedia.org/wiki/UMFPACK "UMFPACK") | | See also [C syntax](https://en.wikipedia.org/wiki/C_syntax "C syntax") [History of C](https://en.wikipedia.org/wiki/C_\(programming_language\)#History) [List of C programming books](https://en.wikipedia.org/wiki/List_of_computer_books#C "List of computer books") [List of C software and tools](https://en.wikipedia.org/wiki/List_of_C_software_and_tools "List of C software and tools") [List of C-family programming languages](https://en.wikipedia.org/wiki/List_of_C-family_programming_languages "List of C-family programming languages") [List of free software programmed in C](https://en.wikipedia.org/wiki/Category:Free_software_programmed_in_C "Category:Free software programmed in C") [Outline of the C programming language](https://en.wikipedia.org/wiki/Outline_of_the_C_programming_language "Outline of the C programming language") | | [![icon](https://upload.wikimedia.org/wikipedia/commons/thumb/6/6f/Octicons-terminal.svg/20px-Octicons-terminal.svg.png)](https://en.wikipedia.org/wiki/File:Octicons-terminal.svg) [Computer programming portal](https://en.wikipedia.org/wiki/Portal:Computer_programming "Portal:Computer programming") [C programming (Wikibooks)](https://en.wikibooks.org/wiki/C_Programming "wikibooks:C Programming") | | [v](https://en.wikipedia.org/wiki/Template:C_sidebar "Template:C sidebar") [t](https://en.wikipedia.org/w/index.php?title=Template_talk:C_sidebar&action=edit&redlink=1 "Template talk:C sidebar (page does not exist)") [e](https://en.wikipedia.org/wiki/Special:EditPage/Template:C_sidebar "Special:EditPage/Template:C sidebar") | **C**[\[c\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-12) is a [general-purpose programming language](https://en.wikipedia.org/wiki/General-purpose_programming_language "General-purpose programming language") created in the 1970s by [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie"). By design, C gives the [programmer](https://en.wikipedia.org/wiki/Programmer "Programmer") relatively direct access to the features of the typical [CPU](https://en.wikipedia.org/wiki/Central_processing_unit "Central processing unit") architecture, customized for the target [instruction set](https://en.wikipedia.org/wiki/Instruction_set_architecture "Instruction set architecture"). It has been and continues to be used to implement [operating systems](https://en.wikipedia.org/wiki/Operating_system "Operating system") (especially [kernels](https://en.wikipedia.org/wiki/Kernel_\(operating_system\) "Kernel (operating system)")[\[10\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-13)), [device drivers](https://en.wikipedia.org/wiki/Device_driver "Device driver"), and [protocol stacks](https://en.wikipedia.org/wiki/Protocol_stack "Protocol stack"), but its use in [application software](https://en.wikipedia.org/wiki/Application_software "Application software") has been decreasing.[\[11\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-14) C is used on computers that range from the largest [supercomputers](https://en.wikipedia.org/wiki/Supercomputer "Supercomputer") to the smallest [microcontrollers](https://en.wikipedia.org/wiki/Microcontroller "Microcontroller") and [embedded systems](https://en.wikipedia.org/wiki/Embedded_system "Embedded system"). A successor to the programming language [B](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)"), C was originally developed at [Bell Labs](https://en.wikipedia.org/wiki/Bell_Labs "Bell Labs") by Ritchie between 1972 and 1973 to construct utilities running on [Unix](https://en.wikipedia.org/wiki/Unix "Unix"). It was applied to re-implementing the kernel of the Unix operating system.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) During the 1980s, C gradually gained popularity. It has become one of the most widely used [programming languages](https://en.wikipedia.org/wiki/Programming_language "Programming language"),[\[13\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-langpop-16)[\[14\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-TIOBE-2009-17) with C [compilers](https://en.wikipedia.org/wiki/Compiler "Compiler") available for practically all modern [computer architectures](https://en.wikipedia.org/wiki/Computer_architecture "Computer architecture") and [operating systems](https://en.wikipedia.org/wiki/Operating_system "Operating system"). The book *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*, co-authored by the original language designer, served for many years as the *de facto* standard for the language.[\[15\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-ward198308-18)[\[1\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-C_in_a_Nutshell-1) C has been standardized since 1989 by the [American National Standards Institute](https://en.wikipedia.org/wiki/American_National_Standards_Institute "American National Standards Institute") (ANSI) and, subsequently, jointly by the [International Organization for Standardization](https://en.wikipedia.org/wiki/International_Organization_for_Standardization "International Organization for Standardization") (ISO) and the [International Electrotechnical Commission](https://en.wikipedia.org/wiki/International_Electrotechnical_Commission "International Electrotechnical Commission") (IEC). C is an [imperative](https://en.wikipedia.org/wiki/Imperative_programming "Imperative programming") [procedural](https://en.wikipedia.org/wiki/Procedural_programming "Procedural programming") language, supporting [structured programming](https://en.wikipedia.org/wiki/Structured_programming "Structured programming"), [lexical variable scope](https://en.wikipedia.org/wiki/Lexical_variable_scope "Lexical variable scope"), and [recursion](https://en.wikipedia.org/wiki/Recursion_\(computer_science\) "Recursion (computer science)"), with a [static type system](https://en.wikipedia.org/wiki/Static_type_system "Static type system"). It was designed to be [compiled](https://en.wikipedia.org/wiki/Compiled "Compiled") to provide [low-level](https://en.wikipedia.org/wiki/Low-level_programming_language "Low-level programming language") access to [memory](https://en.wikipedia.org/wiki/Computer_memory "Computer memory") and language constructs that map efficiently to [machine instructions](https://en.wikipedia.org/wiki/Machine_instructions "Machine instructions"), all with minimal [runtime support](https://en.wikipedia.org/wiki/Runtime_system "Runtime system"). Despite its low-level capabilities, the language was designed to encourage cross-platform programming. A [standards](https://en.wikipedia.org/wiki/Specification_\(technical_standard\) "Specification (technical standard)")\-compliant C program written with [portability](https://en.wikipedia.org/wiki/Software_portability "Software portability") in mind can be compiled for a wide variety of computer platforms and operating systems with few changes to its source code. Although neither C nor its standard library provide some popular features found in other languages, it is flexible enough to support them. For example, [object orientation](https://en.wikipedia.org/wiki/Object-oriented_programming "Object-oriented programming") and [garbage collection](https://en.wikipedia.org/wiki/Garbage_collection_\(computer_science\) "Garbage collection (computer science)") are provided by external libraries [GLib Object System](https://en.wikipedia.org/wiki/GLib_Object_System "GLib Object System") and [Boehm garbage collector](https://en.wikipedia.org/wiki/Boehm_garbage_collector "Boehm garbage collector"), respectively. Since 2000, C has typically ranked as the most or second-most popular language in the [TIOBE index](https://en.wikipedia.org/wiki/TIOBE_index "TIOBE index").[\[16\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-19) ## Characteristics \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=1 "Edit section: Characteristics")\] [![](https://upload.wikimedia.org/wikipedia/commons/thumb/1/1b/Ken_Thompson_and_Dennis_Ritchie--1973.jpg/250px-Ken_Thompson_and_Dennis_Ritchie--1973.jpg)](https://en.wikipedia.org/wiki/File:Ken_Thompson_and_Dennis_Ritchie--1973.jpg) [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (right), the inventor of the C programming language, with [Ken Thompson](https://en.wikipedia.org/wiki/Ken_Thompson "Ken Thompson") The C language exhibits the following characteristics: - [Free-form](https://en.wikipedia.org/wiki/Free-form_language "Free-form language") source code - [Semicolons](https://en.wikipedia.org/wiki/Semicolon "Semicolon") terminate [statements](https://en.wikipedia.org/wiki/Statement_\(programming\) "Statement (programming)") - [Curly braces](https://en.wikipedia.org/wiki/Curly_braces "Curly braces") group statements into [blocks](https://en.wikipedia.org/wiki/Block_\(programming\) "Block (programming)") - [Executable code](https://en.wikipedia.org/wiki/Executable_code "Executable code") is contained in [functions](https://en.wikipedia.org/wiki/Function_\(computer_programming\) "Function (computer programming)") (no script-like syntax) - [Parameters](https://en.wikipedia.org/wiki/Function_parameter "Function parameter") are passed by value; pass by-reference is achieved by passing a pointer to a value - Relatively small number of keywords - [Control flow](https://en.wikipedia.org/wiki/Control_flow "Control flow") constructs, including `if`, `for`, `do`, `while`, and `switch` - [Arithmetic](https://en.wikipedia.org/wiki/Arithmetic "Arithmetic"), [bitwise](https://en.wikipedia.org/wiki/Bitwise "Bitwise"), and logic operators, including `+`,`+=`,`++`,`&`,`||` - Multiple [assignments](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)") may be performed in a single statement - User-defined identifiers are not distinguished from keywords (i.e., by a [sigil](https://en.wikipedia.org/wiki/Sigil_\(computer_programming\) "Sigil (computer programming)")) - A variable declared inside a block is accessible only in that block and only below the declaration - A function return value can be ignored - A function cannot be nested inside a function, but some translators support this - [Run-time polymorphism](https://en.wikipedia.org/wiki/Run-time_polymorphism "Run-time polymorphism") may be achieved using function pointers - Supports [recursion](https://en.wikipedia.org/wiki/Recursion_\(computer_science\) "Recursion (computer science)") - Data typing is [static](https://en.wikipedia.org/wiki/Static_typing "Static typing"), but [weakly enforced](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"); all variables have a type, but [implicit conversion](https://en.wikipedia.org/wiki/Implicit_conversion "Implicit conversion") between primitive types weakens the separation of the different types - [User-defined](https://en.wikipedia.org/wiki/Typedef "Typedef") data types allow for aliasing a data type specifier - Syntax for [array](https://en.wikipedia.org/wiki/Array_\(data_type\) "Array (data type)") definition and access is via square bracket notation, for example `month[11]`. Indexing is defined in terms of pointer arithmetic. Whole arrays cannot be copied or compared without custom or library code - User-defined [structure](https://en.wikipedia.org/wiki/Struct_\(C_programming_language\) "Struct (C programming language)") types allow related data elements to be passed and copied as a unit although two structures cannot be compared without custom code to compare each field - User-defined [union](https://en.wikipedia.org/wiki/Union_type "Union type") types support overlapping members, allowing multiple data types to share the same [memory location](https://en.wikipedia.org/wiki/Memory_location "Memory location") - User-defined [enumeration](https://en.wikipedia.org/wiki/Enumerated_type "Enumerated type") types support aliasing integer values - Lacks a [string type](https://en.wikipedia.org/wiki/String_\(computer_science\) "String (computer science)") but has syntax for [null-terminated strings](https://en.wikipedia.org/wiki/Null-terminated_string "Null-terminated string") with associated [handling](https://en.wikipedia.org/wiki/C_string_handling "C string handling") in its standard library - Supports low-level access to [computer memory](https://en.wikipedia.org/wiki/Computer_memory "Computer memory") via [pointers](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)") - Supports [procedure-like](https://en.wikipedia.org/wiki/Procedure_\(computer_science\) "Procedure (computer science)") construct as a function returning `void` - Supports [dynamic memory](https://en.wikipedia.org/wiki/Dynamic_allocation "Dynamic allocation") via standard library functions - Includes the [C preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") to perform [macro](https://en.wikipedia.org/wiki/Macro_\(computer_science\) "Macro (computer science)") definition, [source code](https://en.wikipedia.org/wiki/Source_code "Source code") file inclusion, and [conditional compilation](https://en.wikipedia.org/wiki/Conditional_compilation "Conditional compilation") - Supports [modularity](https://en.wikipedia.org/wiki/Modular_programming "Modular programming") in that files are processed separately, with visibility control via `static` and `extern` attributes - Minimized functionality in the core language while relatively complex functionality such as [I/O](https://en.wikipedia.org/wiki/Input/output "Input/output"), string manipulation, and mathematical functions supported via standard library functions - Resulting compiled code has relatively straightforward needs on the underlying platform, making it desirable for operating and [embedded](https://en.wikipedia.org/wiki/Embedded_system "Embedded system") systems ## "Hello, world" example \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=2 "Edit section: \"Hello, world\" example")\] [![](https://upload.wikimedia.org/wikipedia/commons/thumb/2/21/Hello_World_Brian_Kernighan_1978.jpg/250px-Hello_World_Brian_Kernighan_1978.jpg)](https://en.wikipedia.org/wiki/File:Hello_World_Brian_Kernighan_1978.jpg) "Hello, World!" program by [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan") (1978) The ["Hello, World!" program](https://en.wikipedia.org/wiki/%22Hello,_World!%22_program "\"Hello, World!\" program") example that appeared in the first edition of *[K\&R](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")* has become the model for an introductory program in most programming textbooks. The program prints "hello, world" to the [standard output](https://en.wikipedia.org/wiki/Standard_output "Standard output"). The original version was:[\[17\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie19786-20) ``` main() { printf("hello, world\n"); } ``` A more modern version is:[\[d\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-21) ``` #include <stdio.h> int main(void) { printf("hello, world\n"); } ``` The first line is a [preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") [directive](https://en.wikipedia.org/wiki/Directive_\(programming\) "Directive (programming)"), indicated by `#include`, which causes the preprocessor to replace that line of code with the text of the `stdio.h` header file, which contains declarations for input and output functions including `printf`. The angle brackets around `stdio.h` indicate that the header file can be located using a search strategy that selects header files provided with the compiler over files with the same name that may be found in project-specific directories. The next code line declares the [entry point](https://en.wikipedia.org/wiki/Entry_point "Entry point") function `main`. The [run-time environment](https://en.wikipedia.org/wiki/Run-time_environment "Run-time environment") calls this function to begin program execution. The type specifier `int` indicates that the function returns an integer value. The `void` parameter list indicates that the function consumes no arguments. The run-time environment actually passes two arguments (typed `int` and `char *[]`), but this implementation ignores them. The ISO C standard (section 5.1.2.2.1) requires syntax that either is void or these two arguments – a special treatment not afforded to other functions. The opening curly brace indicates the beginning of the code that defines the function. The next line of code calls (diverts execution to) the C standard library function `printf` with the [address](https://en.wikipedia.org/wiki/Memory_address "Memory address") of the first character of a null-terminated string specified as a [string literal](https://en.wikipedia.org/wiki/String_literal "String literal"). The text `\n` is an [escape sequence](https://en.wikipedia.org/wiki/Escape_sequence "Escape sequence") that denotes the [newline](https://en.wikipedia.org/wiki/Newline "Newline") character which when output in a terminal results in moving the cursor to the beginning of the next line. Even though `printf` returns an `int` value, it is silently discarded. The semicolon `;` terminates the call statement. The closing curly brace indicates the end of the `main` function. Prior to C99, an explicit `return 0;` statement was required at the end of `main` function, but since C99, the `main` function (as being the initial function call) implicitly returns `0` upon reaching its final closing curly brace.[\[e\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-23) ## History \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=3 "Edit section: History")\] ### Early developments \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=4 "Edit section: Early developments")\] | Year | Informal name | Official standard | |---|---|---| | 1972 | first release | —N/a | | 1978 | [K\&R C](https://en.wikipedia.org/wiki/K%26R_C "K&R C") | —N/a | | 1989, 1990 | [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C"), C89, ISO C, C90 | ANSI X3.159-1989 ISO/IEC 9899:1990 | | 1999 | [C99](https://en.wikipedia.org/wiki/C99 "C99"), C9X | ISO/IEC 9899:1999 | | 2011 | [C11](https://en.wikipedia.org/wiki/C11_\(C_standard_revision\) "C11 (C standard revision)"), C1X | ISO/IEC 9899:2011 | | 2018 | [C17](https://en.wikipedia.org/wiki/C17_\(C_standard_revision\) "C17 (C standard revision)"), C18 | ISO/IEC 9899:2018 | | 2024 | [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)"), C2X | ISO/IEC 9899:2024 | | TBA | [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") | | The origin of C is closely tied to the development of the [Unix](https://en.wikipedia.org/wiki/Unix "Unix") operating system, originally implemented in [assembly language](https://en.wikipedia.org/wiki/Assembly_language "Assembly language") on a [PDP-7](https://en.wikipedia.org/wiki/PDP-7 "PDP-7") by [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") and [Ken Thompson](https://en.wikipedia.org/wiki/Ken_Thompson "Ken Thompson"), incorporating several ideas from colleagues. Eventually, they decided to port the operating system to a [PDP-11](https://en.wikipedia.org/wiki/PDP-11 "PDP-11"). The original PDP-11 version of Unix was also developed in assembly language.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) #### B \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=5 "Edit section: B")\] Main article: [B (programming language)](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)") Thompson wanted a programming language for developing utilities for the new platform. He first tried writing a [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") compiler, but he soon gave up the idea and instead created a cut-down version of the recently developed [systems programming language](https://en.wikipedia.org/wiki/Systems_programming_language "Systems programming language") called [BCPL](https://en.wikipedia.org/wiki/BCPL "BCPL"). The official description of BCPL was not available at the time,[\[19\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-NFDsZ-24) and Thompson modified the syntax to be less 'wordy' and similar to a simplified [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") known as SMALGOL.[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) He called the result [*B*](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)"),[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) describing it as "BCPL semantics with a lot of SMALGOL syntax".[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) Like BCPL, B had a [bootstrapping](https://en.wikipedia.org/wiki/Bootstrapping "Bootstrapping") compiler to facilitate porting to new machines.[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) Ultimately, few utilities were written in B because it was too slow and could not take advantage of PDP-11 features such as [byte](https://en.wikipedia.org/wiki/Byte "Byte") addressability. Unlike BCPL's `// comment` marking comments up to the end of the line, B adopted `/* comment */` as the comment delimiter, more akin to PL/1, and allowing comments to appear in the middle of lines. (BCPL's comment style would be reintroduced in C++.)[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) #### New B and first C release \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=6 "Edit section: New B and first C release")\] In 1971 Ritchie started to improve B, to use the features of the more-powerful PDP-11. A significant addition was a character data type. He called this *New B* (NB).[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) Thompson started to use NB to write the [Unix](https://en.wikipedia.org/wiki/Research_Unix "Research Unix") kernel, and his requirements shaped the direction of the language development.[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25)[\[21\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-unixport-26) Through to 1972, richer types were added to the NB language. NB had arrays of `int` and `char`, and to these types were added pointers, the ability to generate pointers to other types, arrays of all types, and types to be returned from functions. Arrays within expressions were effectively treated as pointers. A new compiler was written, and the language was renamed C.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) The C compiler and some utilities made with it were included in [Version 2 Unix](https://en.wikipedia.org/wiki/Version_2_Unix "Version 2 Unix"), which is also known as [Research Unix](https://en.wikipedia.org/wiki/Research_Unix "Research Unix").[\[22\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-QtqTh-27) #### Structures and Unix kernel re-write \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=7 "Edit section: Structures and Unix kernel re-write")\] At [Version 4 Unix](https://en.wikipedia.org/wiki/Version_4_Unix "Version 4 Unix"), released in November 1973, the [Unix](https://en.wikipedia.org/wiki/Unix "Unix") [kernel](https://en.wikipedia.org/wiki/Kernel_\(operating_system\) "Kernel (operating system)") was extensively re-implemented in C.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) By this time, the C language had acquired some powerful features such as `struct` types. The [preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") was introduced around 1973 at the urging of [Alan Snyder](https://en.wikipedia.org/w/index.php?title=Alan_Snyder_\(computer_scientist\)&action=edit&redlink=1 "Alan Snyder (computer scientist) (page does not exist)") and also in recognition of the usefulness of the file-inclusion mechanisms available in BCPL and [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I"). Its original version provided only included files and simple string replacements: `#include` and `#define` of parameterless macros. Soon after that, it was extended, mostly by [Mike Lesk](https://en.wikipedia.org/wiki/Mike_Lesk "Mike Lesk") and then by John Reiser, to incorporate macros with arguments and [conditional compilation](https://en.wikipedia.org/wiki/Conditional_compilation "Conditional compilation").[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) Unix was one of the first operating system kernels implemented in a language other than [assembly](https://en.wikipedia.org/wiki/Assembly_language "Assembly language"). Earlier instances include the [Multics](https://en.wikipedia.org/wiki/Multics "Multics") system (which was written in [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I")) and [Master Control Program](https://en.wikipedia.org/wiki/Master_Control_Program "Master Control Program") (MCP) for the [Burroughs B5000](https://en.wikipedia.org/wiki/Burroughs_large_systems "Burroughs large systems") (which was written in [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL")) in 1961. In and around 1977, Ritchie and [Stephen C. Johnson](https://en.wikipedia.org/wiki/Stephen_C._Johnson "Stephen C. Johnson") made further changes to the language to facilitate [portability](https://en.wikipedia.org/wiki/Software_portability "Software portability") of the Unix operating system. Johnson's [Portable C Compiler](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler") served as the basis for several implementations of C on new platforms.[\[21\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-unixport-26) ### K\&R C \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=8 "Edit section: K&R C")\] [![](https://upload.wikimedia.org/wikipedia/commons/thumb/0/0e/The_C_Programming_Language%2C_First_Edition_Cover.svg/250px-The_C_Programming_Language%2C_First_Edition_Cover.svg.png)](https://en.wikipedia.org/wiki/File:The_C_Programming_Language,_First_Edition_Cover.svg) The cover of the book *The C Programming Language*, first edition, by [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan") and [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") In 1978 [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan") and [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") published the first edition of *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*.[\[23\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1978-28) Known as *K\&R* from the initials of its authors, the book served for many years as an informal [specification](https://en.wikipedia.org/wiki/Specification_\(technical_standard\) "Specification (technical standard)") of the language. The version of C that it describes is commonly referred to as "**K\&R C**". As this was released in 1978, it is now also referred to as *C78*.[\[24\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-qOvzA-29) The second edition of the book[\[25\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988-30) covers the later [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C") standard, described below. *K\&R* introduced several language features: - [Standard I/O library](https://en.wikipedia.org/wiki/C_file_input/output "C file input/output") - `long int` data type - `unsigned int` data type - Compound assignment operators of the form `=op` (such as `=-`) were changed to the form `op=` (that is, `-=`) to remove the semantic ambiguity created by constructs such as `i=-10`, which had been interpreted as `i =- 10` (decrement `i` by 10) instead of the possibly intended `i = -10` (let `i` be −10). Even after the publication of the 1989 ANSI standard, for many years K\&R C was still considered the "[lowest common denominator](https://en.wikipedia.org/wiki/Lowest_common_denominator_\(computers\) "Lowest common denominator (computers)")" to which C programmers restricted themselves when maximum portability was desired, since many older compilers were still in use, and because carefully written K\&R C code can be legal Standard C as well. Although later versions of C require functions to have an explicit type declaration, K\&R C only requires functions that return a type other than `int` to be declared before use. Functions used without prior declaration were presumed to return `int`. For example: ``` long long_function(); calling_function() { long longvar; register intvar; longvar = long_function(); if (longvar > 1) intvar = 0; else intvar = int_function(); return intvar; } ``` The declaration of `long_function()` (on line 1) is required since it returns `long`; not `int`. Function `int_function` can be called (line 11) even though it is not declared since it returns `int`. Also, variable `intvar` does not need to be declared as type `int` since that is the default type for `register` keyword. Since function declarations did not include information about arguments, [type checks](https://en.wikipedia.org/wiki/Type_checking "Type checking") were not performed, although some compilers would issue a warning if different calls to a function used different numbers or types of arguments. Tools such as Unix's [lint](https://en.wikipedia.org/wiki/Lint_programming_tool "Lint programming tool") utility were developed that (among other things) checked for consistency of function use across multiple source files. In the years following the publication of K\&R C, several features were added to the language, supported by compilers from AT\&T (in particular [PCC](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler")[\[26\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-SkKfZ-31)) and other vendors. These included: - `void` functions; functions returning no value - Functions returning `struct` or `union` types - [Assignment](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)") for `struct` variables - [Enumerated types](https://en.wikipedia.org/wiki/Enumerated_type "Enumerated type") The popularity of the language, lack of agreement on [standard library](https://en.wikipedia.org/wiki/C_standard_library "C standard library") interfaces, and lack of compliance to the K\&R specification, led to standardization efforts.[\[27\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-32) ### ANSI C and ISO C \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=9 "Edit section: ANSI C and ISO C")\] Main article: [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C") During the late 1970s and 1980s, versions of C were implemented for a wide variety of [mainframe computers](https://en.wikipedia.org/wiki/Mainframe_computer "Mainframe computer"), [minicomputers](https://en.wikipedia.org/wiki/Minicomputer "Minicomputer"), and [microcomputers](https://en.wikipedia.org/wiki/Microcomputer "Microcomputer"), including the [IBM PC](https://en.wikipedia.org/wiki/IBM_PC "IBM PC"), as its popularity increased significantly. In 1983 the [American National Standards Institute](https://en.wikipedia.org/wiki/American_National_Standards_Institute "American National Standards Institute") (ANSI) formed a committee, X3J11, to establish a standard specification of C. X3J11 based the C standard on the Unix implementation; however, the non-portable portion of the Unix C library was handed off to the [IEEE](https://en.wikipedia.org/wiki/IEEE "IEEE") [working group](https://en.wikipedia.org/wiki/Working_group "Working group") 1003 to become the basis for the 1988 [POSIX](https://en.wikipedia.org/wiki/POSIX "POSIX") standard. In 1989, the C standard was ratified as ANSI X3.159-1989 "Programming Language C". This version of the language is often referred to as [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C"), Standard C, or sometimes **C89**. In 1990 the ANSI C standard (with formatting changes) was adopted by the [International Organization for Standardization](https://en.wikipedia.org/wiki/International_Organization_for_Standardization "International Organization for Standardization") (ISO) as ISO/IEC 9899:1990, which is sometimes called **C90**. Therefore, the terms "C89" and "C90" refer to the same programming language. ANSI, like other national standards bodies, no longer develops the C standard independently, but defers to the international C standard, maintained by the working group [ISO/IEC JTC1/SC22](https://en.wikipedia.org/wiki/ISO/IEC_JTC1/SC22 "ISO/IEC JTC1/SC22")/WG14. National adoption of an update to the international standard typically occurs within a year of ISO publication. One of the aims of the C standardization process was to produce a [superset](https://en.wikipedia.org/wiki/Superset "Superset") of K\&R C, incorporating many of the subsequently introduced unofficial features. The standards committee also included several additional features such as [function prototypes](https://en.wikipedia.org/wiki/Function_prototype "Function prototype") (borrowed from C++), `void` pointers, support for international [character sets](https://en.wikipedia.org/wiki/Character_sets "Character sets") and [locales](https://en.wikipedia.org/wiki/Locale_\(computer_software\) "Locale (computer software)"), and preprocessor enhancements. Although the [syntax](https://en.wikipedia.org/wiki/C_syntax "C syntax") for parameter declarations was augmented to include the style used in C++, the K\&R interface continued to be permitted, for compatibility with existing source code. C89 is supported by current C compilers, and most modern C code is based on it. Any program written only in Standard C and without any hardware-dependent assumptions will run correctly on any [platform](https://en.wikipedia.org/wiki/Computing_platform "Computing platform") with a conforming C implementation, within its resource limits. Without such precautions, programs may compile only on a certain platform or with a particular compiler, due, for example, to the use of non-standard libraries, such as [GUI](https://en.wikipedia.org/wiki/GUI "GUI") libraries, or to a reliance on compiler- or platform-specific attributes such as the exact size of data types and byte [endianness](https://en.wikipedia.org/wiki/Endianness "Endianness"). In cases where code must be compilable by either standard-conforming or K\&R C-based compilers, the `__STDC__` macro can be used to split the code into Standard and K\&R sections to prevent the use on a K\&R C-based compiler of features available only in Standard C. After the ANSI/ISO standardization process, the C language specification remained relatively static for several years. In 1995, Normative Amendment 1 to the 1990 C standard (ISO/IEC 9899/AMD1:1995, known informally as C95) was published, to correct some details and to add more extensive support for international character sets.[\[28\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-NWUon-33) ### C99 \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=10 "Edit section: C99")\] Main article: [C99](https://en.wikipedia.org/wiki/C99 "C99") The C standard was further revised in the late 1990s, leading to the publication of ISO/IEC 9899:1999 in 1999, which is commonly referred to as "[C99](https://en.wikipedia.org/wiki/C99 "C99")". It has since been amended three times by Technical Corrigenda.[\[29\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-WG14-34) C99 introduced several new features, including [inline functions](https://en.wikipedia.org/wiki/Inline_function "Inline function"), several new [data types](https://en.wikipedia.org/wiki/Data_type "Data type") (including `long long int` and a `complex` type to represent [complex numbers](https://en.wikipedia.org/wiki/Complex_number "Complex number")), [variable-length arrays](https://en.wikipedia.org/wiki/Variable-length_array "Variable-length array") and [flexible array members](https://en.wikipedia.org/wiki/Flexible_array_member "Flexible array member"), improved support for [IEEE 754](https://en.wikipedia.org/wiki/IEEE_754 "IEEE 754") floating point, support for [variadic macros](https://en.wikipedia.org/wiki/Variadic_macro "Variadic macro") (macros of variable [arity](https://en.wikipedia.org/wiki/Arity "Arity")), and support for one-line comments beginning with `//`, as in BCPL or C++. Many of these had already been implemented as extensions in several C compilers. C99 is for the most part backward compatible with C90, but is stricter in some ways; in particular, a declaration that lacks a type specifier no longer has `int` implicitly assumed. A standard macro `__STDC_VERSION__` is defined with value `199901L` to indicate that C99 support is available. [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection"), [Solaris Studio](https://en.wikipedia.org/wiki/Solaris_Studio "Solaris Studio"), and other C compilers now\[*[when?](https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Chronological_items "Wikipedia:Manual of Style/Dates and numbers")*\] support many or all of the new features of C99. The C compiler in [Microsoft Visual C++](https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B "Microsoft Visual C++"), however, implements the C89 standard and those parts of C99 that are required for compatibility with [C++11](https://en.wikipedia.org/wiki/C%2B%2B11 "C++11").[\[30\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-YTKIv-35)\[*[needs update](https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Chronological_items "Wikipedia:Manual of Style/Dates and numbers")*\] In addition, the C99 standard requires support for [identifiers](https://en.wikipedia.org/wiki/Identifier_\(computer_languages\) "Identifier (computer languages)") using [Unicode](https://en.wikipedia.org/wiki/Unicode "Unicode") in the form of escaped characters (e.g. `\u0040` or `\U0001f431`) and suggests support for raw Unicode names. ### C11 \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=11 "Edit section: C11")\] Main article: [C11](https://en.wikipedia.org/wiki/C11_\(C_standard_revision\) "C11 (C standard revision)") Work began in 2007 on another revision of the C standard, informally called "C1X" until its official publication of ISO/IEC 9899:2011 on December 8, 2011. The C standards committee adopted guidelines to limit the adoption of new features that had not been tested by existing implementations. The C11 standard adds numerous new features to C and the library, including type generic macros, anonymous structures, improved Unicode support, atomic operations, multi-threading, and bounds-checked functions. It also makes some portions of the existing C99 library optional, and improves compatibility with C++. The standard macro `__STDC_VERSION__` is defined as `201112L` to indicate that C11 support is available. ### C17 \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=12 "Edit section: C17")\] Main article: [C17](https://en.wikipedia.org/wiki/C17_\(C_standard_revision\) "C17 (C standard revision)") C17 is an informal name for ISO/IEC 9899:2018, a standard for the C programming language published in June 2018. It introduces no new language features, only technical corrections, and clarifications to defects in C11. The standard macro `__STDC_VERSION__` is defined as `201710L` to indicate that C17 support is available. ### C23 \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=13 "Edit section: C23")\] Main article: [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)") C23 is an informal name for the current major C language standard revision. It was known as "C2X" through most of its development. It builds on past releases, introducing features like new keywords, additional meaning for `auto` to provide [type inference](https://en.wikipedia.org/wiki/Type_inference "Type inference") when declaring variables, new types including `nullptr_t` and `_BitInt(N)`, and expansions to the standard library.[\[31\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-36) C23 was published in October 2024 as ISO/IEC 9899:2024.[\[32\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-N3132-37) The standard macro `__STDC_VERSION__` is defined as `202311L` to indicate that C23 support is available. ### C2Y \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=14 "Edit section: C2Y")\] Main article: [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") C2Y is an informal name for the next major C language standard revision, after C23 (C2X), that is hoped to be released later in the 2020s, hence the '2' in "C2Y". An early working draft of C2Y was released in February 2024 as N3220 by the working group [ISO/IEC JTC1/SC22](https://en.wikipedia.org/wiki/ISO/IEC_JTC1/SC22 "ISO/IEC JTC1/SC22")/WG14.[\[33\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-N3220-38) ### Embedded C \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=15 "Edit section: Embedded C")\] Main article: [Embedded C](https://en.wikipedia.org/wiki/Embedded_C "Embedded C") Historically, embedded C programming requires non-standard extensions to the C language to support exotic features such as [fixed-point arithmetic](https://en.wikipedia.org/wiki/Fixed-point_arithmetic "Fixed-point arithmetic"), multiple distinct [memory banks](https://en.wikipedia.org/wiki/Memory_bank "Memory bank"), and basic I/O operations. In 2008, the C Standards Committee published a [technical report](https://en.wikipedia.org/wiki/Technical_report "Technical report") extending the C language[\[34\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-TR18037-39) to address these issues by providing a common standard for all implementations to adhere to. It includes a number of features not available in normal C, such as fixed-point arithmetic, named address spaces, and basic I/O hardware addressing. ## Definition \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=16 "Edit section: Definition")\] Main article: [C syntax](https://en.wikipedia.org/wiki/C_syntax "C syntax") C has a [formal grammar](https://en.wikipedia.org/wiki/Formal_grammar "Formal grammar") specified by the C standard.[\[35\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-h&s5e-40) Line endings are generally not significant in C; however, line boundaries do have significance during the preprocessing phase. Comments may appear either between the delimiters `/*` and `*/`, or (since C99) following `//` until the end of the line. Comments delimited by `/*` and `*/` do not nest, and these sequences of characters are not interpreted as comment delimiters if they appear inside [string](https://en.wikipedia.org/wiki/String_literal "String literal") or character literals.[\[36\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988192-41) C source files contain declarations and function definitions. Function definitions, in turn, contain declarations and [statements](https://en.wikipedia.org/wiki/Statement_\(computer_science\) "Statement (computer science)"). Declarations either define new types using keywords such as `struct`, `union`, and `enum`, or assign types to and perhaps reserve storage for new variables, usually by writing the type followed by the variable name. Keywords such as `char` and `int` specify built-in types. Sections of code are enclosed in braces (`{` and `}`, sometimes called "curly brackets") to limit the scope of declarations and to act as a single statement for control structures. As an imperative language, C uses *statements* to specify actions. The most common statement is an *expression statement*, consisting of an expression to be evaluated, followed by a semicolon; as a [side effect](https://en.wikipedia.org/wiki/Side_effect_\(computer_science\) "Side effect (computer science)") of the evaluation, [functions may be called](https://en.wikipedia.org/wiki/Function_\(computer_programming\) "Function (computer programming)") and [variables assigned](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)") new values. To modify the normal sequential execution of statements, C provides several control-flow statements identified by reserved keywords. [Structured programming](https://en.wikipedia.org/wiki/Structured_programming "Structured programming") is supported by `if` ... \[`else`\] conditional execution and by `do` ... `while`, `while`, and `for` iterative execution (looping). The `for` statement has separate initialization, testing, and reinitialization expressions, any or all of which can be omitted. `break` and `continue` can be used within the loop. Break is used to leave the innermost enclosing loop statement and continue is used to skip to its reinitialisation. There is also a non-structured `goto` statement, which branches directly to the designated [label](https://en.wikipedia.org/wiki/Label_\(computer_science\) "Label (computer science)") within the function. `switch` selects a `case` to be executed based on the value of an integer expression. Different from many other languages, control-flow will [fall through](https://en.wikipedia.org/wiki/Switch_statement#Fallthrough "Switch statement") to the next `case` unless terminated by a `break`. Expressions can use a variety of built-in operators and may contain function calls. The order in which arguments to functions and operands to most operators are evaluated is unspecified. The evaluations may even be interleaved. However, all side effects (including storage to variables) will occur before the next "[sequence point](https://en.wikipedia.org/wiki/Sequence_point "Sequence point")"; sequence points include the end of each expression statement, and the entry to and return from each function call. Sequence points also occur during evaluation of expressions containing certain operators (`&&`, `||`, `?:` and the [comma operator](https://en.wikipedia.org/wiki/Comma_operator "Comma operator")). This permits a high degree of object code optimization by the compiler, but requires C programmers to take more care to obtain reliable results than is needed for other programming languages. Kernighan and Ritchie say in the Introduction of *The C Programming Language*: "C, like any other language, has its blemishes. Some of the operators have the wrong precedence; some parts of the syntax could be better."[\[37\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie19783-42) The C standard did not attempt to correct many of these blemishes, because of the impact of such changes on already existing software. ### Character set \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=17 "Edit section: Character set")\] The basic C source character set includes the following characters:[\[38\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-draft2007-43) - Lowercase and uppercase letters of the [ISO basic Latin alphabet](https://en.wikipedia.org/wiki/ISO_basic_Latin_alphabet "ISO basic Latin alphabet"): `a`–`z`, `A`–`Z` - Decimal digits: `0`–`9` - Graphic characters: `! " # % & ' ( ) * + , - . / : ; < = > ? [ \ ] ^ _ { | } ~` - [Whitespace characters](https://en.wikipedia.org/wiki/Whitespace_character "Whitespace character"): *[space](https://en.wikipedia.org/wiki/Space_\(punctuation\) "Space (punctuation)")*, *[horizontal tab](https://en.wikipedia.org/wiki/Horizontal_tab "Horizontal tab")*, *[vertical tab](https://en.wikipedia.org/wiki/Vertical_tab "Vertical tab")*, *[form feed](https://en.wikipedia.org/wiki/Form_feed "Form feed")*, *[newline](https://en.wikipedia.org/wiki/Newline "Newline")* The *newline* character indicates the end of a text line; it need not correspond to an actual single character, although for convenience C treats it as such. The POSIX standard mandates a [portable character set](https://en.wikipedia.org/wiki/Portable_character_set "Portable character set") which adds a few characters (notably "@") to the basic C source character set. Both standards do not prescribe any particular value encoding—[ASCII](https://en.wikipedia.org/wiki/ASCII "ASCII") and [EBCDIC](https://en.wikipedia.org/wiki/EBCDIC "EBCDIC") both comply with these standards, since they include at least those basic characters, even though they use different encoded values for those characters. Additional multi-byte encoded characters may be used in [string literals](https://en.wikipedia.org/wiki/String_literal "String literal"), but they are not entirely [portable](https://en.wikipedia.org/wiki/Software_portability "Software portability"). Since [C99](https://en.wikipedia.org/wiki/C99 "C99") multi-national Unicode characters can be embedded portably within C source text by using `\uXXXX` or `\UXXXXXXXX` encoding (where `X` denotes a hexadecimal character). The basic C execution character set contains the same characters, along with representations for the [null character](https://en.wikipedia.org/wiki/Null_character "Null character"), [alert](https://en.wikipedia.org/wiki/Bell_character "Bell character"), [backspace](https://en.wikipedia.org/wiki/Backspace "Backspace"), and [carriage return](https://en.wikipedia.org/wiki/Carriage_return "Carriage return").[\[38\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-draft2007-43) [Run-time](https://en.wikipedia.org/wiki/Run_time_\(program_lifecycle_phase\) "Run time (program lifecycle phase)") support for extended character sets has increased with each revision of the C standard. ### Reserved words \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=18 "Edit section: Reserved words")\] All versions of C have [reserved words](https://en.wikipedia.org/wiki/Reserved_words "Reserved words") that are [case sensitive](https://en.wikipedia.org/wiki/Case_sensitive "Case sensitive"). As reserved words, they cannot be used for variable names. C89 has 32 reserved words: - `auto` - `break` - `case` - `char` - `const` - `continue` - `default` - `do` - `double` - `else` - `enum` - `extern` - `float` - `for` - `goto` - `if` - `int` - `long` - `register` - `return` - `short` - `signed` - `sizeof` - `static` - `struct` - `switch` - `typedef` - `union` - `unsigned` - `void` - `volatile` - `while` C99 added five more reserved words: (‡ indicates an alternative spelling alias for a C23 keyword) - `inline` - `restrict` - `_Bool` ‡ - `_Complex` - `_Imaginary` C11 added seven more reserved words:[\[39\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-ISOIEC_9899-44) (‡ indicates an alternative spelling alias for a C23 keyword) - `_Alignas` ‡ - `_Alignof` ‡ - `_Atomic` - `_Generic` - `_Noreturn` - `_Static_assert` ‡ - `_Thread_local` ‡ C23 reserved fifteen more words: - `alignas` - `alignof` - `bool` - `constexpr` - `false` - `nullptr` - `static_assert` - `thread_local` - `true` - `typeof` - `typeof_unqual` - `_BitInt` - `_Decimal32` - `_Decimal64` - `_Decimal128` Most of the recently reserved words begin with an underscore followed by a capital letter, because identifiers of that form were previously reserved by the C standard for use only by implementations. Since existing program source code should not have been using these identifiers, it would not be affected when C implementations started supporting these extensions to the programming language. Some standard headers do define more convenient synonyms for underscored identifiers. Some of those words were added as keywords with their conventional spelling in C23 and the corresponding macros were removed. Prior to C89, `entry` was reserved as a keyword. In the second edition of their book *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*, which describes what became known as C89, Kernighan and Ritchie wrote, "The ... \[keyword\] `entry`, formerly reserved but never used, is no longer reserved." and "The stillborn `entry` keyword is withdrawn."[\[40\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988192,_259-45) ### Operators \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=19 "Edit section: Operators")\] Main article: [Operators in C and C++](https://en.wikipedia.org/wiki/Operators_in_C_and_C%2B%2B "Operators in C and C++") C supports a rich set of [operators](https://en.wikipedia.org/wiki/Operator_\(computer_programming\) "Operator (computer programming)"), which are symbols used within an [expression](https://en.wikipedia.org/wiki/Expression_\(computer_science\) "Expression (computer science)") to specify the manipulations to be performed while evaluating that expression. C has operators for: - [arithmetic](https://en.wikipedia.org/wiki/Arithmetic "Arithmetic"): [`+`](https://en.wikipedia.org/wiki/Addition "Addition"), [`-`](https://en.wikipedia.org/wiki/Subtraction "Subtraction"), [`*`](https://en.wikipedia.org/wiki/Multiplication "Multiplication"), [`/`](https://en.wikipedia.org/wiki/Division_\(mathematics\) "Division (mathematics)"), [`%`](https://en.wikipedia.org/wiki/Modulo_operation "Modulo operation") - [assignment](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)"): `=` - [augmented assignment](https://en.wikipedia.org/wiki/Augmented_assignment "Augmented assignment"): `+=`, `-=`, `*=`, `/=`, `%=`, `&=`, `|=`, `^=`, `<<=`, `>>=` - [bitwise logic](https://en.wikipedia.org/wiki/Bitwise_logic "Bitwise logic"): `~`, `&`, `|`, `^` - [bitwise shifts](https://en.wikipedia.org/wiki/Bitwise_shift "Bitwise shift"): `<<`, `>>` - [Boolean logic](https://en.wikipedia.org/wiki/Boolean_logic "Boolean logic"): `!`, `&&`, `||` - [conditional evaluation](https://en.wikipedia.org/wiki/%3F: "?:"): [`? :`](https://en.wikipedia.org/wiki/%3F: "?:") - equality testing: [`==`](https://en.wikipedia.org/wiki/Equality_\(mathematics\) "Equality (mathematics)"), [`!=`](https://en.wikipedia.org/wiki/Inequality_\(mathematics\) "Inequality (mathematics)") - [calling functions](https://en.wikipedia.org/wiki/Subroutine "Subroutine"): `( )` - [increment and decrement](https://en.wikipedia.org/wiki/Increment_and_decrement_operators "Increment and decrement operators"): `++`, `--` - [member selection](https://en.wikipedia.org/wiki/Record_\(computer_science\) "Record (computer science)"): `.`, `->` - object size: `sizeof` - type: `typeof`, `typeof_unqual` *since C23* - [order relations](https://en.wikipedia.org/wiki/Order_relation "Order relation"): `<`, `<=`, `>`, `>=` - [reference and dereference](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)"): `&`, `*`, `[ ]` - sequencing: [`,`](https://en.wikipedia.org/wiki/Comma_operator "Comma operator") - [subexpression grouping](https://en.wikipedia.org/wiki/Order_of_operations#Programming_languages "Order of operations"): `( )` - [type conversion](https://en.wikipedia.org/wiki/Type_conversion "Type conversion"): `(typename)` C uses the operator `=` (used in mathematics to express equality) to indicate assignment, following the precedent of [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") and [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I"), but unlike [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") and its derivatives. C uses the operator `==` to test for equality. The similarity between the operators for assignment and equality may result in the accidental use of one in place of the other, and in many cases the mistake does not produce an error message (although some compilers produce warnings). For example, the conditional expression `if (a == b + 1)` might mistakenly be written as `if (a = b + 1)`, which will be evaluated as `true` unless the value of `a` is `0` after the assignment.[\[41\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-AutoTX-8-46) The C [operator precedence](https://en.wikipedia.org/wiki/Operator_precedence "Operator precedence") is not always intuitive. For example, the operator `==` binds more tightly than (is executed prior to) the operators `&` (bitwise AND) and `|` (bitwise OR) in expressions such as `x & 1 == 0`, which must be written as `(x & 1) == 0` if that is the coder's intent.[\[42\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-AutoTX-9-47) ### Data types \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=20 "Edit section: Data types")\] Main article: [C data types](https://en.wikipedia.org/wiki/C_data_types "C data types") | | | |---|---| | [![icon](https://upload.wikimedia.org/wikipedia/en/thumb/9/99/Question_book-new.svg/60px-Question_book-new.svg.png)](https://en.wikipedia.org/wiki/File:Question_book-new.svg) | This section **needs additional citations for [verification](https://en.wikipedia.org/wiki/Wikipedia:Verifiability "Wikipedia:Verifiability")**. Please help [improve this article](https://en.wikipedia.org/wiki/Special:EditPage/C_\(programming_language\) "Special:EditPage/C (programming language)") by [adding citations to reliable sources](https://en.wikipedia.org/wiki/Help:Referencing_for_beginners "Help:Referencing for beginners") in this section. Unsourced material may be challenged and removed. *(October 2012)* *([Learn how and when to remove this message](https://en.wikipedia.org/wiki/Help:Maintenance_template_removal "Help:Maintenance template removal"))* | [![](https://upload.wikimedia.org/wikipedia/commons/thumb/3/30/1999_ISO_C_Concepts.png/250px-1999_ISO_C_Concepts.png)](https://en.wikipedia.org/wiki/File:1999_ISO_C_Concepts.png) The [type system](https://en.wikipedia.org/wiki/Type_system "Type system") in C is [static](https://en.wikipedia.org/wiki/Static_typing "Static typing") and [weakly typed](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"), which makes it similar to the type system of [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") descendants such as [Pascal](https://en.wikipedia.org/wiki/Pascal_\(programming_language\) "Pascal (programming language)").[\[43\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Nmlwr-48) There are built-in types for integers of various sizes, both signed and unsigned, [floating-point numbers](https://en.wikipedia.org/wiki/Floating-point_number "Floating-point number"), and enumerated types (`enum`). Integer type `char` is often used for single-byte characters. C99 added a [Boolean data type](https://en.wikipedia.org/wiki/Boolean_data_type "Boolean data type"). There are also derived types including [arrays](https://en.wikipedia.org/wiki/Array_\(data_type\) "Array (data type)"), [pointers](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)"), [records](https://en.wikipedia.org/wiki/Record_\(computer_science\) "Record (computer science)") (`struct`), and [unions](https://en.wikipedia.org/wiki/Union_\(computer_science\) "Union (computer science)") (`union`). C is often used in low-level systems programming where escapes from the type system may be necessary. The compiler attempts to ensure type correctness of most expressions, but the programmer can override the checks in various ways, either by using a *[type cast](https://en.wikipedia.org/wiki/Type_conversion "Type conversion")* to explicitly convert a value from one type to another, or by using pointers or unions to reinterpret the underlying bits of a data object in some other way. Some find C's declaration syntax unintuitive, particularly for [function pointers](https://en.wikipedia.org/wiki/Function_pointer "Function pointer"). (Ritchie's idea was to declare identifiers in contexts resembling their use: "[declaration reflects use](https://en.wikipedia.org/wiki/Declaration_reflects_use "Declaration reflects use")".)[\[44\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988122-49) C's *usual arithmetic conversions* allow for efficient code to be generated, but can sometimes produce unexpected results. For example, a comparison of signed and unsigned integers of equal width requires a conversion of the signed value to unsigned. This can generate unexpected results if the signed value is negative. #### Pointers \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=21 "Edit section: Pointers")\] C supports the use of [pointers](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)"), a type of [reference](https://en.wikipedia.org/wiki/Reference_\(computer_science\) "Reference (computer science)") that records the address or location of an object or function in memory. Pointers can be *dereferenced* to access data stored at the address pointed to, or to invoke a pointed-to function. Pointers can be manipulated using assignment or [pointer arithmetic](https://en.wikipedia.org/wiki/Pointer_arithmetic "Pointer arithmetic"). The run-time representation of a pointer value is typically a raw memory address (perhaps augmented by an offset-within-word field), but since a pointer's type includes the type of the thing pointed to, expressions including pointers can be type-checked at compile time. Pointer arithmetic is automatically scaled by the size of the pointed-to data type. Pointers are used for many purposes in C. [Text strings](https://en.wikipedia.org/wiki/Text_string "Text string") are commonly manipulated using pointers into arrays of characters. [Dynamic memory allocation](https://en.wikipedia.org/wiki/Dynamic_memory_allocation "Dynamic memory allocation") is performed using pointers; the result of a `malloc` is usually [cast](https://en.wikipedia.org/wiki/Type_conversion "Type conversion") to the data type of the data to be stored. Many data types, such as [trees](https://en.wikipedia.org/wiki/Tree_\(data_structure\) "Tree (data structure)"), are commonly implemented as dynamically allocated `struct` objects linked together using pointers. Pointers to other pointers are often used in multi-dimensional arrays and arrays of `struct` objects. Pointers to functions (*[function pointers](https://en.wikipedia.org/wiki/Function_pointer "Function pointer")*) are useful for passing functions as arguments to [higher-order functions](https://en.wikipedia.org/wiki/Higher-order_function "Higher-order function") (such as [qsort](https://en.wikipedia.org/wiki/Qsort "Qsort") or [bsearch](https://en.wikipedia.org/wiki/Bsearch "Bsearch")), in [dispatch tables](https://en.wikipedia.org/wiki/Dispatch_table "Dispatch table"), or as [callbacks](https://en.wikipedia.org/wiki/Callbacks "Callbacks") to [event handlers](https://en.wikipedia.org/wiki/Event_handler "Event handler").[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) A *[null pointer](https://en.wikipedia.org/wiki/Null_pointer "Null pointer") value* explicitly points to no valid location. Dereferencing a null pointer value is undefined, often resulting in a [segmentation fault](https://en.wikipedia.org/wiki/Segmentation_fault "Segmentation fault"). Null pointer values are useful for indicating special cases such as no "next" pointer in the final node of a [linked list](https://en.wikipedia.org/wiki/Linked_list "Linked list"), or as an error indication from functions returning pointers. In appropriate contexts in source code, such as for assigning to a pointer variable, a *null pointer constant* can be written as `0`, with or without explicit casting to a pointer type, as the `NULL` macro defined by several standard headers or, since C23 with the constant `nullptr`. In conditional contexts, null pointer values evaluate to `false`, while all other pointer values evaluate to `true`. Void pointers (`void *`) point to objects of unspecified type, and can therefore be used as "generic" data pointers. Since the size and type of the pointed-to object is not known, void pointers cannot be dereferenced, nor is pointer arithmetic on them allowed, although they can easily be (and in many contexts implicitly are) converted to and from any other object pointer type.[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) Careless use of pointers is potentially dangerous. Because they are typically unchecked, a pointer variable can be made to point to any arbitrary location, which can cause undesirable effects. Although properly used pointers point to safe places, they can be made to point to unsafe places by using invalid [pointer arithmetic](https://en.wikipedia.org/wiki/Pointer_arithmetic "Pointer arithmetic"); the objects they point to may continue to be used after deallocation ([dangling pointers](https://en.wikipedia.org/wiki/Dangling_pointer "Dangling pointer")); they may be used without having been initialized ([wild pointers](https://en.wikipedia.org/wiki/Wild_pointer "Wild pointer")); or they may be directly assigned an unsafe value using a cast, union, or through another corrupt pointer. In general, C is permissive in allowing manipulation of and conversion between pointer types, although compilers typically provide options for various levels of checking. Some other programming languages address these problems by using more restrictive [reference](https://en.wikipedia.org/wiki/Reference_\(computer_science\) "Reference (computer science)") types. #### Arrays \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=22 "Edit section: Arrays")\] See also: [C string handling](https://en.wikipedia.org/wiki/C_string_handling "C string handling") [Array](https://en.wikipedia.org/wiki/Array_\(data_type\) "Array (data type)") types in C are traditionally of a fixed, static size specified at compile time. The more recent C99 standard also allows a form of variable-length arrays. However, it is also possible to allocate a block of memory (of arbitrary size) at run time, using the standard library's `malloc` function, and treat it as an array. Since arrays are always accessed (in effect) via pointers, array accesses are typically not checked against the underlying array size, although some compilers may provide [bounds checking](https://en.wikipedia.org/wiki/Bounds_checking "Bounds checking") as an option.[\[45\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-fedoraproject-50)[\[46\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Programming_with_C-51) Array bounds violations are therefore possible and can lead to various repercussions, including illegal memory accesses, corruption of data, [buffer overruns](https://en.wikipedia.org/wiki/Buffer_overruns "Buffer overruns"), and run-time exceptions. C does not have a special provision for declaring [multi-dimensional arrays](https://en.wikipedia.org/wiki/Multi-dimensional_array "Multi-dimensional array"), but rather relies on [recursion](https://en.wikipedia.org/wiki/Recursion_\(computer_science\) "Recursion (computer science)") within the type system to declare arrays of arrays, which effectively accomplishes the same thing. The index values of the resulting "multi-dimensional array" can be thought of as increasing in [row-major order](https://en.wikipedia.org/wiki/Row-major_order "Row-major order"). Multi-dimensional arrays are commonly used in numerical algorithms (mainly from applied [linear algebra](https://en.wikipedia.org/wiki/Linear_algebra "Linear algebra")) to store matrices. The structure of the C array is well suited to this particular task. However, in early versions of C the bounds of the array must be known fixed values or else explicitly passed to any subroutine that requires them, and dynamically sized arrays of arrays cannot be accessed using double indexing. (A workaround for this was to allocate the array with an additional "row vector" of pointers to the columns.) C99 introduced "variable-length arrays" which address this issue. The following example using modern C (C99 or later) shows allocation of a two-dimensional array on the heap and the use of multi-dimensional array indexing for accesses (which can use bounds-checking on many C compilers): ``` int func(int n, int m) { float (*p)[n][m] = malloc(sizeof *p); if (p == NULL) { return -1; } for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { (*p)[i][j] = i + j; } } print_array(n, m, p); free(p); return 1; } ``` And here is a similar implementation using C99's *Auto [VLA](https://en.wikipedia.org/wiki/Variable_length_array "Variable length array")* feature:[\[f\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-52) ``` int func(int n, int m) { // Caution: checks should be made to ensure n * m * sizeof(float) does NOT exceed limitations for auto VLAs and is within available size of stack. float p[n][m]; // auto VLA is held on the stack, and sized when the function is invoked for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { p[i][j] = i + j; } } print_array(n, m, p); // no need to free(p) since it will disappear when the function exits, along with the rest of the stack frame return 1; } ``` #### Array–pointer interchangeability \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=23 "Edit section: Array–pointer interchangeability")\] The subscript notation `x[i]` (where `x` designates a pointer) is [syntactic sugar](https://en.wikipedia.org/wiki/Syntactic_sugar "Syntactic sugar") for `*(x+i)`.[\[47\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Raymond1996-53) Taking advantage of the compiler's knowledge of the pointer type, the address that `x + i` points to is not the base address (pointed to by `x`) incremented by `i` bytes, but rather is defined to be the base address incremented by `i` multiplied by the size of an element that `x` points to. Thus, `x[i]` designates the `i+1`th element of the array. Furthermore, in most expression contexts (a notable exception is as operand of `sizeof`), an expression of array type is automatically converted to a pointer to the array's first element. This implies that an array is never copied as a whole when named as an argument to a function, but rather only the address of its first element is passed. Therefore, although function calls in C use [pass-by-value](https://en.wikipedia.org/wiki/Pass-by-value "Pass-by-value") semantics, arrays are in effect passed by [reference](https://en.wikipedia.org/wiki/Reference_\(computer_science\) "Reference (computer science)"). The total size of an array `x` can be determined by applying `sizeof` to an expression of array type. The size of an element can be determined by applying the operator `sizeof` to any dereferenced element of an array `A`, as in `n = sizeof A[0]`. Thus, the number of elements in a declared array `A` can be determined as `sizeof A / sizeof A[0]`. Note, that if only a pointer to the first element is available as it is often the case in C code because of the automatic conversion described above, the information about the full type of the array and its length are lost. ### Memory management \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=24 "Edit section: Memory management")\] One of the most important functions of a programming language is to provide facilities for managing [memory](https://en.wikipedia.org/wiki/Computer_memory "Computer memory") and the objects that are stored in memory. C provides three principal ways to allocate memory for objects:[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) - [Static memory allocation](https://en.wikipedia.org/wiki/Static_memory_allocation "Static memory allocation"): space for the object is provided in the binary at compile time; these objects have an [extent](https://en.wikipedia.org/wiki/Variable_\(programming\)#Scope_and_extent "Variable (programming)") (or lifetime) as long as the binary which contains them is loaded into memory. - [Automatic memory allocation](https://en.wikipedia.org/wiki/Automatic_memory_allocation "Automatic memory allocation"): temporary objects can be stored on the [stack](https://en.wikipedia.org/wiki/Call_stack "Call stack"), and this space is automatically freed and reusable after the block in which they are declared is exited. - [Dynamic memory allocation](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation"): blocks of memory of arbitrary size can be requested at run time using library functions such as `malloc` from a region of memory called the [heap](https://en.wikipedia.org/wiki/Memory_management "Memory management"); these blocks persist until subsequently freed for reuse by calling the library function `realloc` or `free`. These three approaches are appropriate in different situations and have various trade-offs. For example, static memory allocation has little allocation overhead, automatic allocation may involve slightly more overhead, and dynamic memory allocation can potentially have a great deal of overhead for both allocation and deallocation. The persistent nature of static objects is useful for maintaining state information across function calls, automatic allocation is easy to use but stack space is typically much more limited and transient than either static memory or heap space, and dynamic memory allocation allows convenient allocation of objects whose size is known only at run time. Most C programs make extensive use of all three. Where possible, automatic or static allocation is usually simplest because the storage is managed by the compiler, freeing the programmer of the potentially error-prone chore of manually allocating and releasing storage. However, many data structures can change in size at run time, and since static allocations (and automatic allocations before C99) must have a fixed size at compile time, there are many situations in which dynamic allocation is necessary.[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) Prior to the C99 standard, variable-sized arrays were a common example of this. (See the article on [C dynamic memory allocation](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation") for an example of dynamically allocated arrays.) Unlike automatic allocation, which can fail at run time with uncontrolled consequences, the dynamic allocation functions return an indication (in the form of a null pointer value) when the required storage cannot be allocated. (Static allocation that is too large is usually detected by the [linker](https://en.wikipedia.org/wiki/Linker_\(computing\) "Linker (computing)") or [loader](https://en.wikipedia.org/wiki/Loader_\(computing\) "Loader (computing)"), before the program can even begin execution.) Unless otherwise specified, static objects contain zero or null pointer values upon program startup. Automatically and dynamically allocated objects are initialized only if an initial value is explicitly specified; otherwise they initially have indeterminate values (typically, whatever [bit pattern](https://en.wikipedia.org/wiki/Bit_pattern "Bit pattern") happens to be present in the [storage](https://en.wikipedia.org/wiki/Computer_storage "Computer storage"), which might not even represent a valid value for that type). If the program attempts to access an uninitialized value, the results are undefined. Many modern compilers try to detect and warn about this problem, but both [false positives and false negatives](https://en.wikipedia.org/wiki/Type_I_and_type_II_errors "Type I and type II errors") can occur. Heap memory allocation has to be synchronized with its actual usage in any program to be reused as much as possible. For example, if the only pointer to a heap memory allocation goes out of scope or has its value overwritten before it is deallocated explicitly, then that memory cannot be recovered for later reuse and is essentially lost to the program, a phenomenon known as a *[memory leak](https://en.wikipedia.org/wiki/Memory_leak "Memory leak")*. Conversely, it is possible for memory to be freed but referenced subsequently, leading to unpredictable results. Typically, the failure symptoms appear in a portion of the program unrelated to the code that causes the error, making it difficult to diagnose the failure. Such issues are ameliorated in languages with [automatic garbage collection](https://en.wikipedia.org/wiki/Automatic_garbage_collection "Automatic garbage collection"). ### Libraries \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=25 "Edit section: Libraries")\] The C programming language uses [libraries](https://en.wikipedia.org/wiki/Library_\(computing\) "Library (computing)") as its primary method of extension. In C, a library is a set of functions contained within a single "archive" file. Each library typically has a [header file](https://en.wikipedia.org/wiki/Header_file "Header file"), which contains the prototypes of the functions contained within the library that may be used by a program, and declarations of special data types and macro symbols used with these functions. For a program to use a library, it must include the library's header file, and the library must be linked with the program, which in many cases requires [compiler flags](https://en.wikipedia.org/wiki/Compiler_flag "Compiler flag") (e.g., `-lm`, shorthand for "link the math library").[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) The most common C library is the [C standard library](https://en.wikipedia.org/wiki/C_standard_library "C standard library"), which is specified by the [ISO](https://en.wikipedia.org/wiki/ISO_standard "ISO standard") and [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C") standards and comes with every C implementation (implementations which target limited environments such as [embedded systems](https://en.wikipedia.org/wiki/Embedded_system "Embedded system") may provide only a subset of the standard library). This library supports stream input and output, memory allocation, mathematics, character strings, and time values. Several separate standard headers (for example, `stdio.h`) specify the interfaces for these and other standard library facilities. Another common set of C library functions are those used by applications specifically targeted for [Unix](https://en.wikipedia.org/wiki/Unix "Unix") and [Unix-like](https://en.wikipedia.org/wiki/Unix-like "Unix-like") systems, especially functions which provide an interface to the [kernel](https://en.wikipedia.org/wiki/Kernel_\(operating_system\) "Kernel (operating system)"). These functions are detailed in various standards such as [POSIX](https://en.wikipedia.org/wiki/POSIX "POSIX") and the [Single UNIX Specification](https://en.wikipedia.org/wiki/Single_UNIX_Specification "Single UNIX Specification"). Since many programs have been written in C, there are a wide variety of other libraries available. Libraries are often written in C because C compilers generate efficient [object code](https://en.wikipedia.org/wiki/Object_code "Object code"); programmers then create interfaces to the library so that the routines can be used from higher-level languages like [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)"), [Perl](https://en.wikipedia.org/wiki/Perl "Perl"), and [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)").[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) #### File handling and streams \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=26 "Edit section: File handling and streams")\] File input and output (I/O) is not part of the C language itself but instead is handled by libraries (such as the C standard library) and their associated header files (e.g. `stdio.h`). File handling is generally implemented through high-level I/O which works through [streams](https://en.wikipedia.org/wiki/Stream_\(computing\) "Stream (computing)"). A stream is from this perspective a data flow that is independent of devices, while a file is a concrete device. The high-level I/O is done through the association of a stream to a file. In the C standard library, a [buffer](https://en.wikipedia.org/wiki/Data_buffer "Data buffer") (a memory area or queue) is temporarily used to store data before it is sent to the final destination. This reduces the time spent waiting for slower devices, for example a [hard drive](https://en.wikipedia.org/wiki/Hard_drive "Hard drive") or [solid-state drive](https://en.wikipedia.org/wiki/Solid-state_drive "Solid-state drive"). Low-level I/O functions are not part of the standard C library\[*[clarification needed](https://en.wikipedia.org/wiki/Wikipedia:Please_clarify "Wikipedia:Please clarify")*\] but are generally part of "bare metal" programming (programming that is independent of any [operating system](https://en.wikipedia.org/wiki/Operating_system "Operating system") such as most [embedded programming](https://en.wikipedia.org/wiki/Embedded_programming "Embedded programming")). With few exceptions, implementations include low-level I/O. ## Language tools \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=27 "Edit section: Language tools")\] See also: [List of C software and tools](https://en.wikipedia.org/wiki/List_of_C_software_and_tools "List of C software and tools") A number of tools have been developed to help C programmers find and fix statements with undefined behavior or possibly erroneous expressions, with greater rigor than that provided by the compiler. Automated source code checking and auditing tools exist, such as [Lint](https://en.wikipedia.org/wiki/Lint_\(software\) "Lint (software)"). A common practice is to use Lint to detect questionable code when a program is first written. Once a program passes Lint, it is then compiled using the C compiler. Also, many compilers can optionally warn about syntactically valid constructs that are likely to actually be errors. [MISRA C](https://en.wikipedia.org/wiki/MISRA_C "MISRA C") is a proprietary set of guidelines to avoid such questionable code, developed for embedded systems.[\[48\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-MI2L0-54) There are also compilers, libraries, and operating system level mechanisms for performing actions that are not a standard part of C, such as [bounds checking](https://en.wikipedia.org/wiki/Bounds_checking "Bounds checking") for arrays, detection of [buffer overflow](https://en.wikipedia.org/wiki/Buffer_overflow "Buffer overflow"), [serialization](https://en.wikipedia.org/wiki/Serialization "Serialization"), [dynamic memory](https://en.wikipedia.org/wiki/Dynamic_memory "Dynamic memory") tracking, and [automatic garbage collection](https://en.wikipedia.org/wiki/Automatic_garbage_collection "Automatic garbage collection"). Memory management checking tools like [Purify](https://en.wikipedia.org/wiki/IBM_Rational_Purify "IBM Rational Purify") or [Valgrind](https://en.wikipedia.org/wiki/Valgrind "Valgrind") and linking with libraries containing special versions of the [memory allocation functions](https://en.wikipedia.org/wiki/Malloc "Malloc") can help uncover run-time errors in memory usage.[\[49\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-55)[\[50\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-56) ## Uses \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=28 "Edit section: Uses")\] C has been widely used to implement [end-user](https://en.wikipedia.org/wiki/End-user_\(computer_science\) "End-user (computer science)") and system-level applications.[\[51\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-57) ### Rationale for use in systems programming \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=29 "Edit section: Rationale for use in systems programming")\] [![](https://upload.wikimedia.org/wikipedia/commons/thumb/1/10/The_C_Programming_Language.png/250px-The_C_Programming_Language.png)](https://en.wikipedia.org/wiki/File:The_C_Programming_Language.png) Some software written in C C is widely used for [systems programming](https://en.wikipedia.org/wiki/Systems_programming "Systems programming") in implementing [operating systems](https://en.wikipedia.org/wiki/Operating_system "Operating system") and [embedded system](https://en.wikipedia.org/wiki/Embedded_system "Embedded system") applications.[\[52\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Zh3CW-58) This is for several reasons: - The C language permits platform hardware and memory to be accessed with pointers and [type punning](https://en.wikipedia.org/wiki/Type_punning "Type punning"), so system-specific features (e.g. [Control/Status Registers](https://en.wikipedia.org/wiki/Control/Status_Register "Control/Status Register"), [I/O registers](https://en.wikipedia.org/wiki/Memory-mapped_I/O "Memory-mapped I/O")) can be configured and used with code written in C – it allows fullest control of the platform it is running on. - The code generated by compilation does not demand many [system features](https://en.wikipedia.org/wiki/Runtime_system "Runtime system"), and can be invoked from some boot code in a straightforward manner – it is simple to execute. - The C language statements and expressions typically map well to sequences of instructions for the target processor, and consequently there is a low [run-time](https://en.wikipedia.org/wiki/Run_time_\(program_lifecycle_phase\) "Run time (program lifecycle phase)") demand on system resources – it is fast to execute. - With its rich set of operators, the C language can use many of the features of target CPUs. Where a particular CPU has more esoteric instructions, a language variant can be constructed with perhaps [intrinsic functions](https://en.wikipedia.org/wiki/Intrinsic_function "Intrinsic function") to exploit those instructions – it can use practically all the target CPU's features. - The language makes it easy to overlay structures onto blocks of binary data, allowing the data to be comprehended, navigated and modified – it can write data structures, even file systems. - The language supports a rich set of operators, including bit manipulation, for integer arithmetic and logic, and perhaps different sizes of floating point numbers – it can process appropriately structured data effectively. - C is a fairly small language, with only a handful of statements, and without too many features that generate extensive target code – it is comprehensible. - C has direct control over memory allocation and deallocation, which gives reasonable efficiency and predictable timing to memory-handling operations, without any concerns for sporadic *[stop-the-world](https://en.wikipedia.org/wiki/Stop-the-world "Stop-the-world")* garbage collection events – it has predictable performance. - C permits the use and implementation of different [memory allocation](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation") schemes, including a typical `malloc` and `free`; a more sophisticated mechanism with [*arenas*](https://en.wikipedia.org/wiki/Region-based_memory_management "Region-based memory management"); or a version for an [OS kernel](https://en.wikipedia.org/wiki/OS_kernel "OS kernel") that may suit [DMA](https://en.wikipedia.org/wiki/Direct_memory_access "Direct memory access"), use within [interrupt handlers](https://en.wikipedia.org/wiki/Interrupt_handler "Interrupt handler"), or integrated with the [virtual memory](https://en.wikipedia.org/wiki/Virtual_memory "Virtual memory") system. - Depending on the linker and environment, C code can also call libraries written in [assembly language](https://en.wikipedia.org/wiki/Assembly_language "Assembly language"), and may be called from assembly language – it interoperates well with other lower-level code. - C and its [calling conventions](https://en.wikipedia.org/wiki/Calling_convention "Calling convention") and linker structures are commonly used in conjunction with other high-level languages, with calls both to C and from C supported – it interoperates well with other high-level code. - C has a mature and broad ecosystem, including libraries, frameworks, open source compilers, debuggers and utilities, and is the de facto standard. It is likely the drivers already exist in C, or that there is a similar CPU architecture as a back-end of a C compiler, so there is reduced incentive to choose another language. ### Games \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=30 "Edit section: Games")\] Computer games are often built from a combination of languages. C has featured significantly, especially for those games attempting to obtain best performance from computer platforms. Examples include [Doom](https://en.wikipedia.org/wiki/Doom_\(1993_video_game\) "Doom (1993 video game)") from 1993.[\[53\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-59) ### World Wide Web \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=31 "Edit section: World Wide Web")\] Historically, C was sometimes used for [web development](https://en.wikipedia.org/wiki/Web_development "Web development") using the [Common Gateway Interface](https://en.wikipedia.org/wiki/Common_Gateway_Interface "Common Gateway Interface") (CGI) as a "gateway" for information between the web application, the server, and the browser.[\[54\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Dobbs_1995-60) C may have been chosen over [interpreted languages](https://en.wikipedia.org/wiki/Interpreted_language "Interpreted language") because of its speed, stability, and near-universal availability.[\[55\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-linuxjournal_2005-61) It is no longer common practice for web development to be done in C,[\[56\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-62) and many other [web development languages](https://en.wikipedia.org/wiki/Web_development#Server-side_languages "Web development") are popular. Applications where C-based web development continues include the [HTTP](https://en.wikipedia.org/wiki/HTTP "HTTP") configuration pages on [routers](https://en.wikipedia.org/wiki/Router_\(computing\) "Router (computing)"), [IoT](https://en.wikipedia.org/wiki/IoT "IoT") devices and similar, although even here some projects have parts in higher-level languages e.g. the use of [Lua](https://en.wikipedia.org/wiki/Lua "Lua") within [OpenWRT](https://en.wikipedia.org/wiki/OpenWRT "OpenWRT"). Two popular [web servers](https://en.wikipedia.org/wiki/Web_server "Web server"), [Apache HTTP Server](https://en.wikipedia.org/wiki/Apache_HTTP_Server "Apache HTTP Server") and [Nginx](https://en.wikipedia.org/wiki/Nginx "Nginx"), are written in C.[\[57\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-63)[\[58\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-64)\[*[better source needed](https://en.wikipedia.org/wiki/Wikipedia:Verifiability#Questionable_sources "Wikipedia:Verifiability")*\] C's close-to-the-metal approach allows for the construction of these high-performance software systems.\[*[citation needed](https://en.wikipedia.org/wiki/Wikipedia:Citation_needed "Wikipedia:Citation needed")*\] ### C as an intermediate language \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=32 "Edit section: C as an intermediate language")\] C is sometimes used as an [intermediate language](https://en.wikipedia.org/wiki/Intermediate_language "Intermediate language") by implementations of other languages. This approach may be used for portability or convenience; by using C as an intermediate language, additional machine-specific code generators are not necessary. C has some features, such as line-number preprocessor directives and optional superfluous commas at the end of initializer lists, that support compilation of generated code. However, some of C's shortcomings have prompted the development of other [C-based languages](https://en.wikipedia.org/wiki/List_of_C-family_programming_languages "List of C-family programming languages") specifically designed for use as intermediate languages, such as [C--](https://en.wikipedia.org/wiki/C-- "C--"). Also, contemporary major compilers [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection") and [LLVM](https://en.wikipedia.org/wiki/LLVM "LLVM") both feature an [intermediate representation](https://en.wikipedia.org/wiki/Intermediate_representation "Intermediate representation") that is not C, and those compilers support front ends for many languages including C. ### Computationally intensive libraries \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=33 "Edit section: Computationally intensive libraries")\] C enables programmers to create efficient implementations of algorithms and data structures, because the layer of abstraction from hardware is thin, and its overhead is low, an important criterion for computationally intensive programs. For example, the [GNU Multiple Precision Arithmetic Library](https://en.wikipedia.org/wiki/GNU_Multiple_Precision_Arithmetic_Library "GNU Multiple Precision Arithmetic Library"), the [GNU Scientific Library](https://en.wikipedia.org/wiki/GNU_Scientific_Library "GNU Scientific Library"), [Mathematica](https://en.wikipedia.org/wiki/Mathematica "Mathematica"), and [MATLAB](https://en.wikipedia.org/wiki/MATLAB "MATLAB") are completely or partially written in C. Many languages support calling library functions in C; for example, the [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)")\-based framework [NumPy](https://en.wikipedia.org/wiki/NumPy "NumPy") uses C for the high-performance and hardware-interacting aspects. ### Other languages are written in C \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=34 "Edit section: Other languages are written in C")\] A consequence of C's wide availability and efficiency is that [compilers](https://en.wikipedia.org/wiki/Compiler "Compiler"), libraries and [interpreters](https://en.wikipedia.org/wiki/Interpreter_\(computing\) "Interpreter (computing)") of other programming languages are often implemented in C.[\[59\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-65) For example, the [reference implementations](https://en.wikipedia.org/wiki/Reference_implementation "Reference implementation") of [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)"),[\[60\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-66) [Perl](https://en.wikipedia.org/wiki/Perl "Perl"),[\[61\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-67) [Ruby](https://en.wikipedia.org/wiki/Ruby_\(programming_language\) "Ruby (programming language)"),[\[62\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-68) and [PHP](https://en.wikipedia.org/wiki/PHP "PHP")[\[63\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-69) are written in C. ## Limitations \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=35 "Edit section: Limitations")\] Ritchie himself joked about the limitations of the language that he created:[\[64\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-70) > the power of assembly language and the convenience of ... assembly language — Dennis Ritchie While C is popular, influential and hugely successful, it has drawbacks, including: - The standard [dynamic memory](https://en.wikipedia.org/wiki/Dynamic_memory "Dynamic memory") handling with `malloc` and `free` is prone to mistakes. Improper use can lead to [memory leaks](https://en.wikipedia.org/wiki/Memory_leaks "Memory leaks") and [dangling pointers](https://en.wikipedia.org/wiki/Dangling_pointers "Dangling pointers").[\[65\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-71) - The use of pointers and the direct manipulation of memory means corruption of memory is possible. - There is [type checking](https://en.wikipedia.org/wiki/Type_checking "Type checking"), yet it does not apply to some areas like [variadic functions](https://en.wikipedia.org/wiki/Variadic_functions "Variadic functions"), and the type checking can be trivially or inadvertently circumvented. It is [weakly typed](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"), despite being statically typed. - Since the code generated by the compiler contains few run-time checks, there is a burden on the programmer to consider all possible outcomes, to protect against buffer overruns, array bounds checking, [stack overflows](https://en.wikipedia.org/wiki/Stack_overflow "Stack overflow"), memory exhaustion, and consider [race conditions](https://en.wikipedia.org/wiki/Race_condition#In_software "Race condition"), thread isolation, etc. - The use of pointers and the run-time manipulation of these enables two ways to access the same data (aliasing), which is not always determinable at compile time. This means that some optimizations that may be available to some other languages, such as Fortran, are not possible in C. For this reason, Fortran is sometimes considered faster.\[*[citation needed](https://en.wikipedia.org/wiki/Wikipedia:Citation_needed "Wikipedia:Citation needed")*\] - Some of the standard library functions, e.g. `scanf` or `strncat`, can lead to [buffer overruns](https://en.wikipedia.org/wiki/C_standard_library#Buffer_overflow_vulnerabilities "C standard library"). - There is limited standardization in support for low-level variants in generated code, such as different function [calling conventions](https://en.wikipedia.org/wiki/Calling_conventions "Calling conventions") and [ABIs](https://en.wikipedia.org/wiki/Application_binary_interface "Application binary interface"); different [structure packing](https://en.wikipedia.org/wiki/Data_structure_alignment "Data structure alignment") conventions; and different byte ordering within larger integers (including endianness). In many language implementations, some of these options may be handled with the preprocessor directive `#pragma`,[\[66\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-72)[\[67\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-73) and some with additional keywords e.g. use `__cdecl` calling convention. The directive and options are not consistently supported.[\[68\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-74) - [String handling](https://en.wikipedia.org/wiki/C_string_handling "C string handling") using the standard library is code-intensive, with explicit memory management required. - The language does not directly support object orientation, [introspection](https://en.wikipedia.org/wiki/Type_introspection "Type introspection"), run-time expression evaluation (like `eval` in JavaScript), garbage collection, etc. - There are few guards against misuse of language features, which may enable [unmaintainable](https://en.wikipedia.org/wiki/Software_maintenance "Software maintenance") code. In particular, the [C preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") can hide troubling effects such as double evaluation and worse.[\[69\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-75) This capability for obfuscated code has been celebrated with competitions such as the [International Obfuscated C Code Contest](https://en.wikipedia.org/wiki/International_Obfuscated_C_Code_Contest "International Obfuscated C Code Contest") and the [Underhanded C Contest](https://en.wikipedia.org/wiki/Underhanded_C_Contest "Underhanded C Contest"). - C lacks standard support for [exception handling](https://en.wikipedia.org/wiki/Exception_handling "Exception handling") and only offers [return codes](https://en.wikipedia.org/wiki/Return_code "Return code") for error checking. The [`setjmp` and `longjmp`](https://en.wikipedia.org/wiki/Setjmp.h "Setjmp.h") standard library functions have been used[\[70\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-76) to implement a try-catch mechanism via macros. Also, `goto` statements are commonly used for error handling.\[*[citation needed](https://en.wikipedia.org/wiki/Wikipedia:Citation_needed "Wikipedia:Citation needed")*\] ### Mitigations for C's problems \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=36 "Edit section: Mitigations for C's problems")\] For some purposes, restricted styles of C have been adopted, e.g. [MISRA C](https://en.wikipedia.org/wiki/MISRA_C "MISRA C") or [CERT C](https://en.wikipedia.org/wiki/CERT_C "CERT C"), in an attempt to reduce the opportunity for unwanted behaviour.[\[71\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-77) Databases such as [CWE](https://en.wikipedia.org/wiki/Common_Weakness_Enumeration "Common Weakness Enumeration") attempt to count the ways that systems in general, especially those coded in C, have potential vulnerabilities, along with recommendations for mitigation. There are [tools](https://en.wikipedia.org/wiki/C_\(programming_language\)#Language_tools) that can mitigate some of the drawbacks. Contemporary C compilers include checks which may generate warnings to help identify many potential bugs. C's use of pointers can be made less risky by use of [instruction set architecture](https://en.wikipedia.org/wiki/Instruction_set_architecture "Instruction set architecture") extensions such as *[CHERI](https://en.wikipedia.org/wiki/CHERI "CHERI")* or *Permission Overlay Extensions*. These techniques change the fundamental nature of pointers at a hardware level to include bounds checks and purposes, which can help prevent buffer over-runs and inappropriate heap accesses. Since the early 2020s the Linux kernel has sections written in [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)"), a language which has specific measures to improve safety.[\[72\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-78) ## Related languages \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=37 "Edit section: Related languages")\] Main article: [List of C-family programming languages](https://en.wikipedia.org/wiki/List_of_C-family_programming_languages "List of C-family programming languages") [![](https://upload.wikimedia.org/wikipedia/commons/thumb/f/ff/TIOBE_Index.webp/250px-TIOBE_Index.webp.png)](https://en.wikipedia.org/wiki/File:TIOBE_Index.webp) [TIOBE index](https://en.wikipedia.org/wiki/TIOBE_index "TIOBE index") Many languages developed after C were influenced by and borrowed aspects of C, including [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++"), [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)"), [C shell](https://en.wikipedia.org/wiki/C_shell "C shell"), [D](https://en.wikipedia.org/wiki/D_\(programming_language\) "D (programming language)"), [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)"), [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)"), [JavaScript](https://en.wikipedia.org/wiki/JavaScript "JavaScript"), [Julia](https://en.wikipedia.org/wiki/Julia_\(programming_language\) "Julia (programming language)"), [Limbo](https://en.wikipedia.org/wiki/Limbo_\(programming_language\) "Limbo (programming language)"), [LPC](https://en.wikipedia.org/wiki/LPC_\(programming_language\) "LPC (programming language)"), [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C"), [Perl](https://en.wikipedia.org/wiki/Perl "Perl"), [PHP](https://en.wikipedia.org/wiki/PHP "PHP"), [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)"), [Ruby](https://en.wikipedia.org/wiki/Ruby_\(programming_language\) "Ruby (programming language)"), [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)"), [Swift](https://en.wikipedia.org/wiki/Swift_\(programming_language\) "Swift (programming language)"), [Verilog](https://en.wikipedia.org/wiki/Verilog "Verilog") and [SystemVerilog](https://en.wikipedia.org/wiki/SystemVerilog "SystemVerilog").[\[8\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-vinsp-10)[\[73\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-kafmy-79) Some claim that the most pervasive influence has been syntactical – that these languages combine the statement and expression syntax of C with type systems, data models and large-scale program structures that differ from those of C, sometimes radically. Several C or near-C interpreters exist, including [Ch](https://en.wikipedia.org/wiki/Ch_\(computer_programming\) "Ch (computer programming)") and [CINT](https://en.wikipedia.org/wiki/CINT "CINT"), which can also be used for scripting. When [object-oriented programming](https://en.wikipedia.org/wiki/Object-oriented_programming "Object-oriented programming") languages became popular, [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") and [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C") were two different extensions of C that provided object-oriented capabilities. Both languages were originally implemented as [source-to-source compilers](https://en.wikipedia.org/wiki/Source-to-source_compiler "Source-to-source compiler"); source code was translated into C, and then compiled with a C compiler.[\[74\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-dSI6f-80) The [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") programming language (originally named "C with [Classes](https://en.wikipedia.org/wiki/Class_\(programming\) "Class (programming)")") was devised by [Bjarne Stroustrup](https://en.wikipedia.org/wiki/Bjarne_Stroustrup "Bjarne Stroustrup") as an approach to providing [object-oriented](https://en.wikipedia.org/wiki/Object-oriented_programming "Object-oriented programming") functionality with a C-like syntax.[\[75\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-stroustrup_1993-81) C++ adds greater typing strength, scoping, and other tools useful in object-oriented programming, and permits [generic programming](https://en.wikipedia.org/wiki/Generic_programming "Generic programming") via templates. Nearly a superset of C, C++ now\[*[when?](https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Chronological_items "Wikipedia:Manual of Style/Dates and numbers")*\] supports most of C, with [a few exceptions](https://en.wikipedia.org/wiki/Compatibility_of_C_and_C%2B%2B "Compatibility of C and C++"). [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C") was originally a thin layer on top of C, and remains a strict [superset](https://en.wikipedia.org/wiki/Superset "Superset") of C that permits object-oriented programming using a hybrid dynamic/static typing paradigm. Objective-C derives its syntax from both C and [Smalltalk](https://en.wikipedia.org/wiki/Smalltalk "Smalltalk"): syntax that involves preprocessing, expressions, function declarations, and function calls is inherited from C, while the syntax for object-oriented features was originally taken from Smalltalk. In addition to [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") and [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C"), [Ch](https://en.wikipedia.org/wiki/Ch_\(computer_programming\) "Ch (computer programming)"), [Cilk](https://en.wikipedia.org/wiki/Cilk "Cilk"), and [Unified Parallel C](https://en.wikipedia.org/wiki/Unified_Parallel_C "Unified Parallel C") are nearly supersets of C. ## See also \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=38 "Edit section: See also")\] - [Comparison of Pascal and C](https://en.wikipedia.org/wiki/Comparison_of_Pascal_and_C "Comparison of Pascal and C") - [Comparison of programming languages](https://en.wikipedia.org/wiki/Comparison_of_programming_languages "Comparison of programming languages") - [List of C compilers](https://en.wikipedia.org/wiki/List_of_C_compilers "List of C compilers") - [List of C programming books](https://en.wikipedia.org/wiki/List_of_computer_books#C "List of computer books") - [Outline of the C programming language](https://en.wikipedia.org/wiki/Outline_of_the_C_programming_language "Outline of the C programming language") ## Notes \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=39 "Edit section: Notes")\] 1. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-5)** "Thompson had made a brief attempt to produce a system coded in an early version of C—before structures—in 1972, but gave up the effort."[\[2\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a9-2)[\[3\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993b9-3)[\[4\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie2003-4) 2. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-9)** "The scheme of type composition adopted by C owes considerable debt to Algol 68, although it did not, perhaps, emerge in a form that Algol's adherents would approve of."[\[6\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a8-7)[\[7\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993b8-8)[\[4\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie2003-4) 3. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-12)** Pronounced [/ˈsiː/](https://en.wikipedia.org/wiki/Help:IPA/English "Help:IPA/English"), like the letter '[c](https://en.wikipedia.org/wiki/C "C")'.[\[9\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-11) 4. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-21)** The original example code will compile on most modern compilers that are not in strict standard compliance mode, but it does not fully conform to the requirements of either C89 or C99. In fact, C99 requires that a diagnostic message be produced. 5. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-23)** Return value `0` is typically used in this context to indicate success.[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) 6. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-52)** Code of `print_array` (not shown) slightly differs also, because of the type of *p*, being a pointer to the 2D array in the malloc'd version, and just a 2D array in the auto VNA version. ## References \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=40 "Edit section: References")\] 1. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-C_in_a_Nutshell_1-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-C_in_a_Nutshell_1-1) Prinz, Peter; Crawford, Tony (December 16, 2005). [*C in a Nutshell*](https://books.google.com/books?id=4Mfe4sAMFUYC). O'Reilly Media, Inc. p. 3. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-596-55071-4](https://en.wikipedia.org/wiki/Special:BookSources/978-0-596-55071-4 "Special:BookSources/978-0-596-55071-4") . 2. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a9_2-0)** [Ritchie (1993a)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993a), p. 9. 3. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993b9_3-0)** [Ritchie (1993b)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993b), p. 9. 4. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie2003_4-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie2003_4-1) [Ritchie (2003)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie2003). 5. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-6)** ["N3221 – Editor's Report, Post January 2024 Strasbourg France Meeting"](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3221.htm). *ISO/IEC JTC1/SC22/WG14*. Open Standards. February 21, 2024. Retrieved May 24, 2024. 6. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a8_7-0)** [Ritchie (1993a)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993a), p. 8. 7. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993b8_8-0)** [Ritchie (1993b)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993b), p. 8. 8. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-vinsp_10-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-vinsp_10-1) ["Verilog HDL (and C)"](https://web.archive.org/web/20131106064022/http://cs.anu.edu.au/courses/ENGN3213/lectures/lecture6_VERILOG_2010.pdf) (PDF). The Research School of Computer Science at the Australian National University. June 3, 2010. Archived from [the original](http://cs.anu.edu.au/courses/ENGN3213/lectures/lecture6_VERILOG_2010.pdf) (PDF) on November 6, 2013. Retrieved August 19, 2013. "1980s: Verilog first introduced; Verilog inspired by the C programming language" 9. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-11)** ["The name is based on, and pronounced like the letter C in the English alphabet"](https://web.archive.org/web/20221117151137/https://eng.ichacha.net/pronounce/the%20c%20programming%20language.html). *the c programming language sound*. English Chinese Dictionary. Archived from [the original](https://eng.ichacha.net/pronounce/the%20c%20programming%20language.html) on November 17, 2022. Retrieved November 17, 2022. 10. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-13)** Munoz, Daniel. ["After All These Years, the World is Still Powered by C Programming \| Toptal"](https://www.toptal.com/c/after-all-these-years-the-world-is-still-powered-by-c-programming). *Toptal Engineering Blog*. Retrieved June 15, 2024. 11. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-14)** ["C Language Drops to Lowest Popularity Rating"](https://web.archive.org/web/20220822225609/https://www.developer.com/news/c-language-drops-to-lowest-popularity-rating/). *Developer.com*. August 9, 2016. Archived from [the original](https://www.developer.com/news/c-language-drops-to-lowest-popularity-rating/) on August 22, 2022. Retrieved August 1, 2022. 12. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-1) [***c***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-2) [***d***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-3) [***e***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-4) [***f***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-5) [***g***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-6) [Ritchie (1993a)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993a). 13. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-langpop_16-0)** ["Programming Language Popularity"](https://web.archive.org/web/20090116080326/http://www.langpop.com/). 2009. Archived from [the original](https://www.langpop.com/) on January 16, 2009. Retrieved January 16, 2009. 14. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-TIOBE-2009_17-0)** ["TIOBE Programming Community Index"](https://web.archive.org/web/20090504181627/http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html). 2009. Archived from [the original](https://www.tiobe.com/index.php/content/paperinfo/tpci/index.html) on May 4, 2009. Retrieved May 6, 2009. 15. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-ward198308_18-0)** Ward, Terry A. (August 1983). ["Annotated C / A Bibliography of the C Language"](https://archive.org/stream/byte-magazine-1983-08/1983_08_BYTE_08-08_The_C_Language#page/n267/mode/2up). *Byte*. p. 268. Retrieved January 31, 2015. 16. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-19)** ["TIOBE Index for September 2024"](https://web.archive.org/web/20240918165843/https://www.tiobe.com/tiobe-index/). Archived from [the original](https://www.tiobe.com/tiobe-index/) on September 18, 2024. Retrieved December 16, 2025. 17. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie19786_20-0)** [Kernighan & Ritchie (1978)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1978), p. 6. 18. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-1) [***c***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-2) [***d***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-3) [***e***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-4) [***f***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-5) [***g***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-6) [Klemens, Ben](https://en.wikipedia.org/wiki/Ben_Klemens "Ben Klemens") (2013). *21st Century C*. [O'Reilly Media](https://en.wikipedia.org/wiki/O%27Reilly_Media "O'Reilly Media"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-4493-2714-9](https://en.wikipedia.org/wiki/Special:BookSources/978-1-4493-2714-9 "Special:BookSources/978-1-4493-2714-9") . 19. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-NFDsZ_24-0)** Ritchie, Dennis. ["BCPL to B to C"](https://web.archive.org/web/20191212221532/http://www.lysator.liu.se/c/dmr-on-histories.html). *lysator.liu.se*. Archived from [the original](https://www.lysator.liu.se/c/dmr-on-histories.html) on December 12, 2019. Retrieved September 10, 2019. 20. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-1) [***c***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-2) [***d***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-3) [***e***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-4) Jensen, Richard (December 9, 2020). [""A damn stupid thing to do"—the origins of C"](https://web.archive.org/web/20220328143845/https://arstechnica.com/features/2020/12/a-damn-stupid-thing-to-do-the-origins-of-c/). *Ars Technica*. Archived from [the original](https://arstechnica.com/features/2020/12/a-damn-stupid-thing-to-do-the-origins-of-c/) on March 28, 2022. Retrieved March 28, 2022. 21. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-unixport_26-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-unixport_26-1) [Johnson, S. C.](https://en.wikipedia.org/wiki/Stephen_C._Johnson "Stephen C. Johnson"); [Ritchie, D. M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1978). "Portability of C Programs and the UNIX System". *Bell System Tech. J*. **57** (6): 2021–2048\. [CiteSeerX](https://en.wikipedia.org/wiki/CiteSeerX_\(identifier\) "CiteSeerX (identifier)") [10\.1.1.138.35](https://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.138.35). [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1002/j.1538-7305.1978.tb02141.x](https://doi.org/10.1002%2Fj.1538-7305.1978.tb02141.x). [ISSN](https://en.wikipedia.org/wiki/ISSN_\(identifier\) "ISSN (identifier)") [0005-8580](https://search.worldcat.org/issn/0005-8580). [S2CID](https://en.wikipedia.org/wiki/S2CID_\(identifier\) "S2CID (identifier)") [17510065](https://api.semanticscholar.org/CorpusID:17510065). (Note: The PDF is an OCR scan of the original, and contains a rendering of "IBM 370" as "IBM 310".) 22. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-QtqTh_27-0)** [McIlroy, M. D.](https://en.wikipedia.org/wiki/Doug_McIlroy "Doug McIlroy") (1987). [*A Research Unix reader: annotated excerpts from the Programmer's Manual, 1971–1986*](https://web.archive.org/web/20171111151817/http://www.cs.dartmouth.edu/~doug/reader.pdf) (PDF) (Technical report). CSTR. Bell Labs. p. 10. 139. Archived from [the original](http://www.cs.dartmouth.edu/~doug/reader.pdf) (PDF) on November 11, 2017. Retrieved February 1, 2015. 23. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1978_28-0)** [Kernighan & Ritchie (1978)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1978). 24. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-qOvzA_29-0)** "C manual pages". [*FreeBSD Miscellaneous Information Manual*](https://web.archive.org/web/20210121024455/https://nxmnpg.lemoda.net/7/c78) (FreeBSD 13.0 ed.). May 30, 2011. Archived from [the original](https://nxmnpg.lemoda.net/7/c78) on January 21, 2021. Retrieved January 15, 2021. [\[1\]](https://www.freebsd.org/cgi/man.cgi?query=c78&apropos=0&sektion=0&manpath=FreeBSD+9-current&arch=default&format=html) [Archived](https://web.archive.org/web/20210121033654/https://www.freebsd.org/cgi/man.cgi?query=c78&apropos=0&sektion=0&manpath=FreeBSD+9-current&arch=default&format=html) January 21, 2021, at the [Wayback Machine](https://en.wikipedia.org/wiki/Wayback_Machine "Wayback Machine") 25. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988_30-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988). 26. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-SkKfZ_31-0)** [Stroustrup, Bjarne](https://en.wikipedia.org/wiki/Bjarne_Stroustrup "Bjarne Stroustrup") (2002). [Sibling rivalry: C and C++](https://web.archive.org/web/20140824072719/http://www.stroustrup.com/sibling_rivalry.pdf) (PDF) (Report). AT\&T Labs. Archived from [the original](http://stroustrup.com/sibling_rivalry.pdf) (PDF) on August 24, 2014. Retrieved April 14, 2014. 27. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-32)** ["Rationale for American National Standard for Information Systems – Programming Language – C"](https://web.archive.org/web/20240717164722/https://www.cs.man.ac.uk/~pjj/cs211/c_rationale/node2.html). Archived from [the original](https://www.cs.man.ac.uk/~pjj/cs211/c_rationale/node2.html) on July 17, 2024. Retrieved July 17, 2024. 28. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-NWUon_33-0)** [*C Integrity*](https://web.archive.org/web/20180725033429/https://www.iso.org/standard/23909.html). International Organization for Standardization. March 30, 1995. Archived from [the original](https://www.iso.org/standard/23909.html) on July 25, 2018. Retrieved July 24, 2018. 29. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-WG14_34-0)** ["JTC1/SC22/WG14 – C"](https://web.archive.org/web/20180212100115/http://www.open-std.org/JTC1/SC22/WG14/). *Home page*. ISO/IEC. Archived from [the original](http://www.open-std.org/jtc1/sc22/wg14/) on February 12, 2018. Retrieved June 2, 2011. 30. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-YTKIv_35-0)** Andrew Binstock (October 12, 2011). ["Interview with Herb Sutter"](https://web.archive.org/web/20130802070446/http://www.drdobbs.com/cpp/interview-with-herb-sutter/231900562). *[Dr. Dobbs](https://en.wikipedia.org/wiki/Dr._Dobbs "Dr. Dobbs")*. Archived from [the original](http://www.drdobbs.com/cpp/interview-with-herb-sutter/231900562) on August 2, 2013. Retrieved September 7, 2013. 31. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-36)** ["ISO/IEC 9899:2024 (en) — N3220 working draft"](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3220.pdf) (PDF). Retrieved July 11, 2025. 32. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-N3132_37-0)** ["WG14-N3132 : Revised C23 Schedule"](https://web.archive.org/web/20230609204739/https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3132.pdf) (PDF). *open-std.org*. June 4, 2023. Archived from [the original](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3132.pdf) (PDF) on June 9, 2023. 33. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-N3220_38-0)** ["WG14-N3220 : Working Draft, C2y"](https://web.archive.org/web/20240226053735/https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3220.pdf) (PDF). *open-std.org*. February 21, 2024. Archived from [the original](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3220.pdf) (PDF) on February 26, 2024. 34. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-TR18037_39-0)** ["TR 18037: Embedded C"](https://web.archive.org/web/20210225224616/https://www.open-std.org/jtc1/sc22/wg14/www/docs/n1169.pdf) (PDF). *open-std.org*. April 4, 2006. ISO/IEC JTC1 SC22 WG14 N1169. Archived from [the original](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n1169.pdf) (PDF) on February 25, 2021. Retrieved July 26, 2011. 35. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-h&s5e_40-0)** Harbison, Samuel P.; [Steele, Guy L.](https://en.wikipedia.org/wiki/Guy_L._Steele,_Jr. "Guy L. Steele, Jr.") (2002). *C: A Reference Manual* (5th ed.). [Englewood Cliffs, NJ](https://en.wikipedia.org/wiki/Englewood_Cliffs,_NJ "Englewood Cliffs, NJ"): [Prentice Hall](https://en.wikipedia.org/wiki/Prentice_Hall "Prentice Hall"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-089592-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-089592-9 "Special:BookSources/978-0-13-089592-9") . Contains a [BNF](https://en.wikipedia.org/wiki/Backus%E2%80%93Naur_form "Backus–Naur form") grammar for C. 36. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988192_41-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988), p. 192. 37. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie19783_42-0)** [Kernighan & Ritchie (1978)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1978), p. 3. 38. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-draft2007_43-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-draft2007_43-1) ["Committee Draft ISO/IEC 9899:TC3: 5.2.1 Character sets"](https://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf). 2007. 39. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-ISOIEC_9899_44-0)** ["ISO/IEC 9899:201x (ISO C11) Committee Draft"](https://web.archive.org/web/20171222215122/http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1548.pdf) (PDF). *open-std.org*. December 2, 2010. Archived from [the original](http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1548.pdf) (PDF) on December 22, 2017. Retrieved September 16, 2011. 40. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988192,_259_45-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988), pp. 192, 259. 41. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-AutoTX-8_46-0)** ["10 Common Programming Mistakes in C++"](https://web.archive.org/web/20081021080953/http://www.cs.ucr.edu/~nxiao/cs10/errors.htm). *Cs.ucr.edu*. Archived from [the original](http://www.cs.ucr.edu/~nxiao/cs10/errors.htm) on October 21, 2008. Retrieved June 26, 2009. 42. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-AutoTX-9_47-0)** Schultz, Thomas (2004). [*C and the 8051*](https://books.google.com/books?id=rI0c8kWbxooC&pg=PT47) (3rd ed.). Otsego, MI: PageFree Publishing Inc. p. 20. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-58961-237-2](https://en.wikipedia.org/wiki/Special:BookSources/978-1-58961-237-2 "Special:BookSources/978-1-58961-237-2") . Retrieved February 10, 2012. 43. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Nmlwr_48-0)** Feuer, Alan R.; Gehani, Narain H. (March 1982). "Comparison of the Programming Languages C and Pascal". *ACM Computing Surveys*. **14** (1): 73–92\. [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1145/356869.356872](https://doi.org/10.1145%2F356869.356872). [S2CID](https://en.wikipedia.org/wiki/S2CID_\(identifier\) "S2CID (identifier)") [3136859](https://api.semanticscholar.org/CorpusID:3136859). 44. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988122_49-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988), p. 122. 45. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-fedoraproject_50-0)** For example, gcc provides \_FORTIFY\_SOURCE. ["Security Features: Compile Time Buffer Checks (FORTIFY\_SOURCE)"](https://web.archive.org/web/20070107153447/http://fedoraproject.org/wiki/Security/Features). fedoraproject.org. Archived from [the original](https://fedoraproject.org/wiki/Security/Features) on January 7, 2007. Retrieved August 5, 2012. 46. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Programming_with_C_51-0)** เอี่ยมสิริวงศ์, โอภาศ (2016). *Programming with C*. Bangkok, Thailand: SE-EDUCATION PUBLIC COMPANY LIMITED. pp. 225–230\. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-616-08-2740-4](https://en.wikipedia.org/wiki/Special:BookSources/978-616-08-2740-4 "Special:BookSources/978-616-08-2740-4") . 47. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Raymond1996_53-0)** [Raymond, Eric S.](https://en.wikipedia.org/wiki/Eric_S._Raymond "Eric S. Raymond") (October 11, 1996). [*The New Hacker's Dictionary*](https://books.google.com/books?id=g80P_4v4QbIC&pg=PA432) (3rd ed.). MIT Press. p. 432. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-262-68092-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-262-68092-9 "Special:BookSources/978-0-262-68092-9") . Retrieved August 5, 2012. 48. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-MI2L0_54-0)** ["Man Page for lint (freebsd Section 1)"](http://www.unix.com/man-page/FreeBSD/1/lint). *unix.com*. May 24, 2001. Retrieved July 15, 2014. 49. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-55)** Hardison, Nate. ["CS107 Valgrind Memcheck"](https://web.stanford.edu/class/archive/cs/cs107/cs107.1236/resources/valgrind.html). *web.stanford.edu*. Retrieved June 23, 2023. 50. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-56)** Hastings, Reed; Joyce, Bob. ["Purify: Fast Detection of Memory Leaks and Access Errors"](https://web.stanford.edu/class/cs343/resources/purify.pdf) (PDF). *Pure Software Inc.*: 9. 51. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-57)** Munoz, Daniel. ["After All These Years, the World is Still Powered by C Programming"](https://www.toptal.com/c/after-all-these-years-the-world-is-still-powered-by-c-programming). *Toptal Engineering Blog*. Retrieved November 17, 2023. 52. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Zh3CW_58-0)** Dale, Nell B.; Weems, Chip (2014). *Programming and problem solving with C++* (6th ed.). Burlington, Massachusetts: Jones & Bartlett Learning. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-4496-9428-9](https://en.wikipedia.org/wiki/Special:BookSources/978-1-4496-9428-9 "Special:BookSources/978-1-4496-9428-9") . [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [894992484](https://search.worldcat.org/oclc/894992484). 53. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-59)** ["Development of Doom"](https://doomwiki.org/wiki/Development_of_Doom). *DoomWiki.org*. March 2, 2025. Retrieved March 2, 2025. 54. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Dobbs_1995_60-0)** *Dr. Dobb's Sourcebook*. U.S.: Miller Freeman, Inc. November–December 1995. 55. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-linuxjournal_2005_61-0)** ["Using C for CGI Programming"](https://web.archive.org/web/20100213075858/http://www.linuxjournal.com/article/6863). linuxjournal.com. March 1, 2005. Archived from [the original](http://www.linuxjournal.com/article/6863) on February 13, 2010. Retrieved January 4, 2010. 56. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-62)** Perkins, Luc (September 17, 2013). ["Web development in C: crazy? Or crazy like a fox?"](https://web.archive.org/web/20141004135317/https://medium.com/@lucperkins/web-development-in-c-crazy-or-crazy-like-a-fox-ff723209f8f5). *Medium*. Archived from [the original](https://medium.com/@lucperkins/web-development-in-c-crazy-or-crazy-like-a-fox-ff723209f8f5) on October 4, 2014. Retrieved April 8, 2022. 57. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-63)** ["What programming language does NGINX use?"](https://mull-overthing.com/what-programming-language-does-nginx-use/). 58. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-64)** ["What is Apache and What Does it Do for Website Development?"](https://www.greengeeks.com/blog/what-is-apache/). February 15, 2022. 59. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-65)** ["C – the mother of all languages"](https://web.archive.org/web/20210531161841/https://ict.iitk.ac.in/c-the-mother-of-all-languages/). *ICT Academy at IITK*. November 13, 2018. Archived from [the original](https://ict.iitk.ac.in/c-the-mother-of-all-languages/) on May 31, 2021. Retrieved October 11, 2022. 60. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-66)** ["1. Extending Python with C or C++"](https://web.archive.org/web/20121105232707/https://docs.python.org/3/extending/extending.html). *Python 3.10.7 documentation*. Archived from [the original](https://docs.python.org/3/extending/extending.html) on November 5, 2012. Retrieved October 11, 2022. 61. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-67)** Conrad, Michael (January 22, 2018). ["An overview of the Perl 5 engine"](https://web.archive.org/web/20220526105419/https://opensource.com/article/18/1/perl-5-engine). *Opensource.com*. Archived from [the original](https://opensource.com/article/18/1/perl-5-engine) on May 26, 2022. Retrieved October 11, 2022. 62. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-68)** ["To Ruby From C and C++"](https://web.archive.org/web/20130812003928/https://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-c-and-cpp/). *Ruby Programming Language*. Archived from [the original](https://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-c-and-cpp/) on August 12, 2013. Retrieved October 11, 2022. 63. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-69)** Para, Michael (August 3, 2022). ["What is PHP? How to Write Your First PHP Program"](https://web.archive.org/web/20220804050401/https://www.freecodecamp.org/news/what-is-php-write-your-first-php-program/). *freeCodeCamp*. Archived from [the original](https://www.freecodecamp.org/news/what-is-php-write-your-first-php-program/) on August 4, 2022. Retrieved October 11, 2022. 64. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-70)** Metz, Cade (October 13, 2011). ["Dennis Ritchie: The Shoulders Steve Jobs Stood On"](https://web.archive.org/web/20220412005125/http://www.wired.com/2011/10/thedennisritchieeffect/). *Wired*. Archived from [the original](https://www.wired.com/2011/10/thedennisritchieeffect/) on April 12, 2022. Retrieved April 19, 2022. 65. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-71)** Internet Security Research Group. ["What is memory safety and why does it matter?"](https://www.memorysafety.org/docs/memory-safety/). *Prossimo*. Retrieved March 3, 2025. 66. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-72)** corob-msft (March 31, 2022). ["Pragma directives and the \_\_pragma and \_Pragma keywords"](https://web.archive.org/web/20220924075131/https://learn.microsoft.com/en-us/cpp/preprocessor/pragma-directives-and-the-pragma-keyword). *Microsoft Learn*. Archived from [the original](https://learn.microsoft.com/en-us/cpp/preprocessor/pragma-directives-and-the-pragma-keyword) on September 24, 2022. Retrieved September 24, 2022. 67. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-73)** ["Pragmas (The C Preprocessor)"](https://web.archive.org/web/20020617041757/https://gcc.gnu.org/onlinedocs/cpp/Pragmas.html). *GCC, the GNU Compiler Collection*. Archived from [the original](https://gcc.gnu.org/onlinedocs/cpp/Pragmas.html) on June 17, 2002. Retrieved September 24, 2022. 68. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-74)** ["Pragmas"](https://web.archive.org/web/20220410113529/https://www.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/pragmas.html). *Intel C++ Compiler Classic Developer Guide and Reference*. Intel. Archived from [the original](https://www.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/pragmas.html) on April 10, 2022. Retrieved April 10, 2022. 69. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-75)** ["In praise of the C preprocessor"](https://apenwarr.ca/log/20070813). *apenwarr*. August 13, 2007. Retrieved July 9, 2023. 70. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-76)** Roberts, Eric S. (March 21, 1989). ["Implementing Exceptions in C"](https://web.archive.org/web/20170115152453/http://bitsavers.informatik.uni-stuttgart.de/pdf/dec/tech_reports/SRC-RR-40.pdf) (PDF). [DEC Systems Research Center](https://en.wikipedia.org/wiki/DEC_Systems_Research_Center "DEC Systems Research Center"). SRC-RR-40. Archived from [the original](http://bitsavers.informatik.uni-stuttgart.de/pdf/dec/tech_reports/SRC-RR-40.pdf) (PDF) on January 15, 2017. Retrieved January 4, 2022. 71. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-77)** ["Secure Coding Overview"](https://apps.dtic.mil/sti/pdfs/AD1090471.pdf) (PDF). Software Engineering Institute, Carnegie Mellon University. Retrieved December 15, 2025. 72. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-78)** ["New Linux Patch Confirms: Rust Experiment Is Done, Rust Is Here To Stay"](https://www.phoronix.com/news/Rust-To-Stay-Linux-Kernel). *www.phoronix.com*. Retrieved December 15, 2025. 73. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-kafmy_79-0)** O'Regan, Gerard (September 24, 2015). *Pillars of computing : a compendium of select, pivotal technology firms*. Springer. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-3-319-21464-1](https://en.wikipedia.org/wiki/Special:BookSources/978-3-319-21464-1 "Special:BookSources/978-3-319-21464-1") . [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [922324121](https://search.worldcat.org/oclc/922324121). 74. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-dSI6f_80-0)** Rauchwerger, Lawrence (2004). *Languages and compilers for parallel computing : 16th international workshop, LCPC 2003, College Station, TX, USA, October 2–4, 2003 : revised papers*. Springer. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-3-540-24644-2](https://en.wikipedia.org/wiki/Special:BookSources/978-3-540-24644-2 "Special:BookSources/978-3-540-24644-2") . [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [57965544](https://search.worldcat.org/oclc/57965544). 75. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-stroustrup_1993_81-0)** [Stroustrup, Bjarne](https://en.wikipedia.org/wiki/Bjarne_Stroustrup "Bjarne Stroustrup") (1993). ["A History of C++: 1979–1991"](https://web.archive.org/web/20190202050609/http://www.stroustrup.com/hopl2.pdf) (PDF). Archived from [the original](http://www.stroustrup.com/hopl2.pdf) (PDF) on February 2, 2019. Retrieved June 9, 2011. ## Sources \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=41 "Edit section: Sources")\] - [Kernighan, Brian W.](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan"); [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1978). [*The C Programming Language*](https://archive.org/details/cprogramminglang00kern/page/n2) (1st ed.). Englewood Cliffs: [Prentice Hall](https://en.wikipedia.org/wiki/Prentice_Hall "Prentice Hall"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-110163-0](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-110163-0 "Special:BookSources/978-0-13-110163-0") . [LCCN](https://en.wikipedia.org/wiki/LCCN_\(identifier\) "LCCN (identifier)") [77028983](https://lccn.loc.gov/77028983). [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [3608698](https://search.worldcat.org/oclc/3608698). [OL](https://en.wikipedia.org/wiki/OL_\(identifier\) "OL (identifier)") [4558528M](https://openlibrary.org/books/OL4558528M). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q63565563](https://www.wikidata.org/wiki/Q63565563 "d:Q63565563"). - [Kernighan, Brian W.](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan"); [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1988). [*The C Programming Language*](https://archive.org/details/cprogramminglang00bria/page/n4) (2nd ed.). Upper Saddle River: [Prentice Hall](https://en.wikipedia.org/wiki/Prentice_Hall "Prentice Hall"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-110362-7](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-110362-7 "Special:BookSources/978-0-13-110362-7") . [LCCN](https://en.wikipedia.org/wiki/LCCN_\(identifier\) "LCCN (identifier)") [88005934](https://lccn.loc.gov/88005934). [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [254455874](https://search.worldcat.org/oclc/254455874). [OL](https://en.wikipedia.org/wiki/OL_\(identifier\) "OL (identifier)") [2030445M](https://openlibrary.org/books/OL2030445M). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q63413168](https://www.wikidata.org/wiki/Q63413168 "d:Q63413168"). - [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (March 1993a). [Wexelblat, Richard L.](https://en.wikipedia.org/wiki/Richard_Wexelblat "Richard Wexelblat") (ed.). ["The Development of the C Language"](https://dl.acm.org/doi/10.1145/155360.155580). *ACM SIGPLAN Notices*. **28** (3). New York City: [Association for Computing Machinery](https://en.wikipedia.org/wiki/Association_for_Computing_Machinery "Association for Computing Machinery"): 201–208\. [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1145/155360.155580](https://doi.org/10.1145%2F155360.155580). [ISSN](https://en.wikipedia.org/wiki/ISSN_\(identifier\) "ISSN (identifier)") [0362-1340](https://search.worldcat.org/issn/0362-1340). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q55869040](https://www.wikidata.org/wiki/Q55869040 "d:Q55869040"). - [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1993b). Bergin, Thomas J.; Gibson, Richard G. (eds.). ["The Development of the C Language"](https://dl.acm.org/doi/10.1145/154766.155580). *The Second ACM SIGPLAN Conference on History of Programming Languages (HOPL-II)*. New York City: [Association for Computing Machinery](https://en.wikipedia.org/wiki/Association_for_Computing_Machinery "Association for Computing Machinery"): 201–208\. [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1145/154766.155580](https://doi.org/10.1145%2F154766.155580). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q29392176](https://www.wikidata.org/wiki/Q29392176 "d:Q29392176"). - [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (2003) \[1993\]. [*The Development of the C Language*](https://web.archive.org/web/20250130134200/https://www.bell-labs.com/usr/dmr/www/chist.html). [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie"). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q134885774](https://www.wikidata.org/wiki/Q134885774 "d:Q134885774"). Archived from [the original](https://www.bell-labs.com/usr/dmr/www/chist.html) on January 30, 2025 – via Bell Labs/Lucent Technologies. ## Further reading \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=42 "Edit section: Further reading")\] - [Plauger, P.J.](https://en.wikipedia.org/wiki/P._J._Plauger "P. J. Plauger") (1992). *The Standard C Library* (1 ed.). Prentice Hall. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-131509-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-131509-9 "Special:BookSources/978-0-13-131509-9") . [*(source)*](https://github.com/wuzhouhui/c_standard_lib) - Banahan, M.; Brady, D.; Doran, M. (1991). *The C Book: Featuring the ANSI C Standard* (2 ed.). Addison-Wesley. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-201-54433-6](https://en.wikipedia.org/wiki/Special:BookSources/978-0-201-54433-6 "Special:BookSources/978-0-201-54433-6") . [*(free)*](https://github.com/wardvanwanrooij/thecbook) - Feuer, Alan R. (1985). *The C Puzzle Book* (1 ed.). Prentice Hall. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [0-13-109934-5](https://en.wikipedia.org/wiki/Special:BookSources/0-13-109934-5 "Special:BookSources/0-13-109934-5") . - Harbison, Samuel; Steele, Guy Jr. (2002). *C: A Reference Manual* (5 ed.). Pearson. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-089592-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-089592-9 "Special:BookSources/978-0-13-089592-9") . [*(archive)*](https://archive.org/details/creferencemanual00harb) - King, K.N. (2008). *C Programming: A Modern Approach* (2 ed.). W. W. Norton. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-393-97950-3](https://en.wikipedia.org/wiki/Special:BookSources/978-0-393-97950-3 "Special:BookSources/978-0-393-97950-3") . [*(archive)*](https://archive.org/details/cprogrammingmode0000king) - Griffiths, David; Griffiths, Dawn (2012). *Head First C* (1 ed.). O'Reilly. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-4493-9991-7](https://en.wikipedia.org/wiki/Special:BookSources/978-1-4493-9991-7 "Special:BookSources/978-1-4493-9991-7") . - Perry, Greg; Miller, Dean (2013). *C Programming: Absolute Beginner's Guide* (3 ed.). Que. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-7897-5198-0](https://en.wikipedia.org/wiki/Special:BookSources/978-0-7897-5198-0 "Special:BookSources/978-0-7897-5198-0") . - Deitel, Paul; Deitel, Harvey (2015). *C: How to Program* (8 ed.). Pearson. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-397689-2](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-397689-2 "Special:BookSources/978-0-13-397689-2") . - Gustedt, Jens (2019). *Modern C* (2 ed.). Manning. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-61729-581-2](https://en.wikipedia.org/wiki/Special:BookSources/978-1-61729-581-2 "Special:BookSources/978-1-61729-581-2") . *[(free)](https://gustedt.gitlabpages.inria.fr/modern-c/)* ## External links \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=43 "Edit section: External links")\] [![logo](https://upload.wikimedia.org/wikipedia/commons/thumb/d/df/Wikibooks-logo-en-noslogan.svg/40px-Wikibooks-logo-en-noslogan.svg.png)](https://en.wikipedia.org/wiki/File:Wikibooks-logo-en-noslogan.svg) Wikibooks has a book on the topic of: ***[C Programming](https://en.wikibooks.org/wiki/C_Programming "wikibooks:C Programming")*** - [ISO C Working Group official website](https://www.open-std.org/jtc1/sc22/wg14/) - [ISO/IEC 9899](https://www.open-std.org/JTC1/SC22/WG14/www/standards), publicly available official C documents, including the C99 Rationale - ["C99 with Technical corrigenda TC1, TC2, and TC3 included"](https://web.archive.org/web/20071025205438/http://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf) (PDF). Archived from [the original](https://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf) (PDF) on October 25, 2007. (3.61 MB) - [comp.lang.c Frequently Asked Questions](https://c-faq.com/) - [A History of C](https://csapp.cs.cmu.edu/3e/docs/chistory.html), by Dennis Ritchie - [C Library Reference and Examples](https://en.cppreference.com/w/c) [Portal](https://en.wikipedia.org/wiki/Wikipedia:Contents/Portals "Wikipedia:Contents/Portals"): - [![icon](https://upload.wikimedia.org/wikipedia/commons/thumb/6/6f/Octicons-terminal.svg/20px-Octicons-terminal.svg.png)](https://en.wikipedia.org/wiki/File:Octicons-terminal.svg) [Computer programming](https://en.wikipedia.org/wiki/Portal:Computer_programming "Portal:Computer programming") **C (programming language)** at Wikipedia's [sister projects](https://en.wikipedia.org/wiki/Wikipedia:Wikimedia_sister_projects "Wikipedia:Wikimedia sister projects"): - [![Wikimedia Commons logo](https://upload.wikimedia.org/wikipedia/en/thumb/4/4a/Commons-logo.svg/20px-Commons-logo.svg.png)](https://en.wikipedia.org/wiki/File:Commons-logo.svg)**[Media](https://commons.wikimedia.org/wiki/Category:C_\(programming_language\) "c:Category:C (programming language)")** from Commons - ![](https://upload.wikimedia.org/wikipedia/commons/thumb/f/fa/Wikiquote-logo.svg/20px-Wikiquote-logo.svg.png)**[Quotations](https://en.wikiquote.org/wiki/C_\(programming_language\) "q:C (programming language)")** from Wikiquote - [![Wikibooks logo](https://upload.wikimedia.org/wikipedia/commons/thumb/f/fa/Wikibooks-logo.svg/20px-Wikibooks-logo.svg.png)](https://en.wikipedia.org/wiki/File:Wikibooks-logo.svg)**[Textbooks](https://en.wikibooks.org/wiki/C_Programming "b:C Programming")** from Wikibooks - [![Wikiversity logo](https://upload.wikimedia.org/wikipedia/commons/thumb/0/0b/Wikiversity_logo_2017.svg/40px-Wikiversity_logo_2017.svg.png)](https://en.wikipedia.org/wiki/File:Wikiversity_logo_2017.svg)**[Resources](https://en.wikiversity.org/wiki/C "v:C")** from Wikiversity | [v](https://en.wikipedia.org/wiki/Template:C_programming_language "Template:C programming language") [t](https://en.wikipedia.org/wiki/Template_talk:C_programming_language "Template talk:C programming language") [e](https://en.wikipedia.org/wiki/Special:EditPage/Template:C_programming_language "Special:EditPage/Template:C programming language")[C programming language]() | | |---|---| | [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C") [C99](https://en.wikipedia.org/wiki/C99 "C99") [C11](https://en.wikipedia.org/wiki/C11_\(C_standard_revision\) "C11 (C standard revision)") [C17](https://en.wikipedia.org/wiki/C17_\(C_standard_revision\) "C17 (C standard revision)") [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)") [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") [Embedded C](https://en.wikipedia.org/wiki/Embedded_C "Embedded C") [MISRA C](https://en.wikipedia.org/wiki/MISRA_C "MISRA C") | | | Features | [Functions](https://en.wikipedia.org/wiki/Subroutine "Subroutine") [Header files](https://en.wikipedia.org/wiki/Include_directive#C "Include directive") [Operators](https://en.wikipedia.org/wiki/Operators_in_C_and_C%2B%2B "Operators in C and C++") [String](https://en.wikipedia.org/wiki/C_string_handling "C string handling") [Syntax](https://en.wikipedia.org/wiki/C_syntax "C syntax") [Preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") [Data types](https://en.wikipedia.org/wiki/C_data_types "C data types") | | [Standard library](https://en.wikipedia.org/wiki/C_standard_library "C standard library") | | | | | | [Char](https://en.wikipedia.org/wiki/C_character_classification "C character classification") [File I/O](https://en.wikipedia.org/wiki/C_file_input/output "C file input/output") [Math](https://en.wikipedia.org/wiki/C_mathematical_functions "C mathematical functions") [Dynamic memory](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation") [String](https://en.wikipedia.org/wiki/C_string_handling "C string handling") [Time](https://en.wikipedia.org/wiki/C_date_and_time_functions "C date and time functions") [Variadic](https://en.wikipedia.org/wiki/Stdarg.h "Stdarg.h") [POSIX](https://en.wikipedia.org/wiki/C_POSIX_library "C POSIX library") | | | Implementations | [Bionic](https://en.wikipedia.org/wiki/Bionic_\(software\) "Bionic (software)") [libhybris](https://en.wikipedia.org/wiki/Hybris_\(software\) "Hybris (software)") [dietlibc](https://en.wikipedia.org/wiki/Dietlibc "Dietlibc") [glibc](https://en.wikipedia.org/wiki/Glibc "Glibc") [EGLIBC](https://en.wikipedia.org/wiki/Embedded_GLIBC "Embedded GLIBC") [klibc](https://en.wikipedia.org/wiki/Klibc "Klibc") [Windows CRT](https://en.wikipedia.org/wiki/Microsoft_Windows_library_files "Microsoft Windows library files") [musl](https://en.wikipedia.org/wiki/Musl "Musl") [Newlib](https://en.wikipedia.org/wiki/Newlib "Newlib") [uClibc](https://en.wikipedia.org/wiki/UClibc "UClibc") | | [Compilers](https://en.wikipedia.org/wiki/List_of_C_compilers "List of C compilers") | [ACK](https://en.wikipedia.org/wiki/Amsterdam_Compiler_Kit "Amsterdam Compiler Kit") [Borland Turbo C](https://en.wikipedia.org/wiki/Borland_Turbo_C "Borland Turbo C") [Clang](https://en.wikipedia.org/wiki/Clang "Clang") [Comeau C/C++](https://en.wikipedia.org/wiki/Comeau_C/C%2B%2B "Comeau C/C++") [CompCert](https://en.wikipedia.org/wiki/CompCert "CompCert") [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection") [IAR Embedded Workbench](https://en.wikipedia.org/wiki/IAR_Systems#IAR_Embedded_Workbench "IAR Systems") [ICC](https://en.wikipedia.org/wiki/Intel_C%2B%2B_Compiler "Intel C++ Compiler") [LCC](https://en.wikipedia.org/wiki/LCC_\(compiler\) "LCC (compiler)") [Norcroft C](https://en.wikipedia.org/wiki/Norcroft_C_compiler "Norcroft C compiler") [PCC](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler") [SDCC](https://en.wikipedia.org/wiki/Small_Device_C_Compiler "Small Device C Compiler") [TCC](https://en.wikipedia.org/wiki/Tiny_C_Compiler "Tiny C Compiler") [Visual C++ (MSVC)](https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B "Microsoft Visual C++") [Watcom C/C++](https://en.wikipedia.org/wiki/Watcom_C/C%2B%2B "Watcom C/C++") | | [IDEs](https://en.wikipedia.org/wiki/Integrated_development_environment "Integrated development environment") | [Anjuta](https://en.wikipedia.org/wiki/Anjuta "Anjuta") [CLion](https://en.wikipedia.org/wiki/CLion "CLion") [Code::Blocks](https://en.wikipedia.org/wiki/Code::Blocks "Code::Blocks") [CodeLite](https://en.wikipedia.org/wiki/CodeLite "CodeLite") [Eclipse](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)") [Geany](https://en.wikipedia.org/wiki/Geany "Geany") [GNOME Builder](https://en.wikipedia.org/wiki/GNOME_Builder "GNOME Builder") [KDevelop](https://en.wikipedia.org/wiki/KDevelop "KDevelop") [NetBeans](https://en.wikipedia.org/wiki/NetBeans "NetBeans") [Visual Studio](https://en.wikipedia.org/wiki/Visual_Studio "Visual Studio") | | Comparison with other languages | [Compatibility of C and C++](https://en.wikipedia.org/wiki/Compatibility_of_C_and_C%2B%2B "Compatibility of C and C++") [Comparison with Pascal](https://en.wikipedia.org/wiki/Comparison_of_Pascal_and_C "Comparison of Pascal and C") | | Descendant languages | [Alef](https://en.wikipedia.org/wiki/Alef_\(programming_language\) "Alef (programming language)") [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)") [D](https://en.wikipedia.org/wiki/D_\(programming_language\) "D (programming language)") [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C") [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)") [Vala](https://en.wikipedia.org/wiki/Vala_\(programming_language\) "Vala (programming language)") [Zig](https://en.wikipedia.org/wiki/Zig_\(programming_language\) "Zig (programming language)") | | Designer | [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") | | ![](https://upload.wikimedia.org/wikipedia/en/thumb/9/96/Symbol_category_class.svg/20px-Symbol_category_class.svg.png) **[Category](https://en.wikipedia.org/wiki/Category:C_\(programming_language\) "Category:C (programming language)")** | | | [v](https://en.wikipedia.org/wiki/Template:Integrated_development_environments "Template:Integrated development environments") [t](https://en.wikipedia.org/wiki/Template_talk:Integrated_development_environments "Template talk:Integrated development environments") [e](https://en.wikipedia.org/wiki/Special:EditPage/Template:Integrated_development_environments "Special:EditPage/Template:Integrated development environments")[Integrated development environments](https://en.wikipedia.org/wiki/Integrated_development_environment "Integrated development environment") | | |---|---| | [C](), [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Arduino](https://en.wikipedia.org/wiki/Arduino "Arduino") [Code::Blocks](https://en.wikipedia.org/wiki/Code::Blocks "Code::Blocks") [CodeLite](https://en.wikipedia.org/wiki/CodeLite "CodeLite") [Dev-C++](https://en.wikipedia.org/wiki/Dev-C%2B%2B "Dev-C++") [Eclipse](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)") [Emacs](https://en.wikipedia.org/wiki/Emacs "Emacs") [Geany](https://en.wikipedia.org/wiki/Geany "Geany") [GNOME Builder](https://en.wikipedia.org/wiki/GNOME_Builder "GNOME Builder") [Kakoune](https://en.wikipedia.org/wiki/Kakoune "Kakoune") [KDevelop](https://en.wikipedia.org/wiki/KDevelop "KDevelop") [NetBeans](https://en.wikipedia.org/wiki/NetBeans "NetBeans") QDevelop [Qt Creator](https://en.wikipedia.org/wiki/Qt_Creator "Qt Creator") [TheIDE](https://en.wikipedia.org/wiki/Ultimate%2B%2B "Ultimate++") [Vi](https://en.wikipedia.org/wiki/Vi_\(text_editor\) "Vi (text editor)")–[Vim](https://en.wikipedia.org/wiki/Vim_\(text_editor\) "Vim (text editor)") [OpenWatcom](https://en.wikipedia.org/wiki/Watcom_C/C%2B%2B "Watcom C/C++") | | [Freeware](https://en.wikipedia.org/wiki/Freeware "Freeware") | [DevEco Studio](https://en.wikipedia.org/wiki/DevEco_Studio "DevEco Studio") [Oracle Developer Studio](https://en.wikipedia.org/wiki/Oracle_Developer_Studio "Oracle Developer Studio") [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") [Visual Studio Community](https://en.wikipedia.org/wiki/Visual_Studio#Community "Visual Studio") [Xcode](https://en.wikipedia.org/wiki/Xcode "Xcode") | | [Retail](https://en.wikipedia.org/wiki/Retail_software "Retail software") | [C++Builder](https://en.wikipedia.org/wiki/C%2B%2BBuilder "C++Builder") [Eclipse](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)")\-based [CodeWarrior](https://en.wikipedia.org/wiki/CodeWarrior "CodeWarrior") [MyEclipse](https://en.wikipedia.org/wiki/MyEclipse "MyEclipse") [Visual Studio](https://en.wikipedia.org/wiki/Visual_Studio "Visual Studio") By [JetBrains](https://en.wikipedia.org/wiki/JetBrains "JetBrains") [IntelliJ IDEA](https://en.wikipedia.org/wiki/IntelliJ_IDEA "IntelliJ IDEA") [CLion](https://en.wikipedia.org/wiki/CLion "CLion") [LabWindows/CVI](https://en.wikipedia.org/wiki/LabWindows/CVI "LabWindows/CVI") IBM [Rational Software Architect](https://en.wikipedia.org/wiki/Rational_Software_Architect "Rational Software Architect") [Understand](https://en.wikipedia.org/wiki/Understand_\(software\) "Understand (software)") [SlickEdit](https://en.wikipedia.org/wiki/SlickEdit "SlickEdit") | | Discontinued | [Anjuta](https://en.wikipedia.org/wiki/Anjuta "Anjuta") By [JetBrains](https://en.wikipedia.org/wiki/JetBrains "JetBrains") [AppCode](https://en.wikipedia.org/wiki/AppCode "AppCode") [VisualAge](https://en.wikipedia.org/wiki/VisualAge "VisualAge") [Visual C++ Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#Visual_C++_Express "Microsoft Visual Studio Express") [MonoDevelop](https://en.wikipedia.org/wiki/MonoDevelop "MonoDevelop") [SharpDevelop](https://en.wikipedia.org/wiki/SharpDevelop "SharpDevelop") [Turbo C](https://en.wikipedia.org/wiki/Turbo_C "Turbo C"), [C++](https://en.wikipedia.org/wiki/Turbo_C%2B%2B "Turbo C++") [QuickC](https://en.wikipedia.org/wiki/QuickC "QuickC") | | [Java](https://en.wikipedia.org/wiki/Java_\(software_platform\) "Java (software platform)") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Anjuta](https://en.wikipedia.org/wiki/Anjuta "Anjuta") [BlueJ](https://en.wikipedia.org/wiki/BlueJ "BlueJ") [DrJava](https://en.wikipedia.org/wiki/DrJava "DrJava") [Eclipse](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)") [Geany](https://en.wikipedia.org/wiki/Geany "Geany") [Greenfoot](https://en.wikipedia.org/wiki/Greenfoot "Greenfoot") [IntelliJ IDEA](https://en.wikipedia.org/wiki/IntelliJ_IDEA "IntelliJ IDEA") Community Edition [Android Studio](https://en.wikipedia.org/wiki/Android_Studio "Android Studio") [NetBeans](https://en.wikipedia.org/wiki/NetBeans "NetBeans") [DevEco Studio](https://en.wikipedia.org/wiki/DevEco_Studio "DevEco Studio") | | [Freeware](https://en.wikipedia.org/wiki/Freeware "Freeware") | [jGRASP](https://en.wikipedia.org/wiki/JGRASP "JGRASP") [JDeveloper](https://en.wikipedia.org/wiki/JDeveloper "JDeveloper") | | [Retail](https://en.wikipedia.org/wiki/Retail_software "Retail software") | JCreator [MyEclipse](https://en.wikipedia.org/wiki/MyEclipse "MyEclipse") [JetBrains](https://en.wikipedia.org/wiki/JetBrains "JetBrains") [IntelliJ IDEA](https://en.wikipedia.org/wiki/IntelliJ_IDEA "IntelliJ IDEA") [SlickEdit](https://en.wikipedia.org/wiki/SlickEdit "SlickEdit") [Understand](https://en.wikipedia.org/wiki/Understand_\(software\) "Understand (software)") | | Discontinued | Metrowerks [CodeWarrior](https://en.wikipedia.org/wiki/CodeWarrior "CodeWarrior") Pro for Java [JBuilder](https://en.wikipedia.org/wiki/JBuilder "JBuilder") [Sun Java Studio Creator](https://en.wikipedia.org/wiki/Sun_Java_Studio_Creator "Sun Java Studio Creator") (superseded by [NetBeans](https://en.wikipedia.org/wiki/NetBeans "NetBeans")) [VisualAge](https://en.wikipedia.org/wiki/VisualAge "VisualAge") (superseded by [Eclipse](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)")) [Visual Café](https://en.wikipedia.org/wiki/Visual_Caf%C3%A9 "Visual Café") (aka Espresso, superseded by [JBuilder](https://en.wikipedia.org/wiki/JBuilder "JBuilder")) [Visual J++](https://en.wikipedia.org/wiki/Visual_J%2B%2B "Visual J++") [Xelfi](https://en.wikipedia.org/wiki/Xelfi "Xelfi") (became [NetBeans](https://en.wikipedia.org/wiki/NetBeans "NetBeans")) | | [JavaScript](https://en.wikipedia.org/wiki/JavaScript "JavaScript") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Vim](https://en.wikipedia.org/wiki/Vim_\(text_editor\) "Vim (text editor)") [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") [Atom](https://en.wikipedia.org/wiki/Atom_\(text_editor\) "Atom (text editor)") [Chromium](https://en.wikipedia.org/wiki/Chromium_\(web_browser\) "Chromium (web browser)") [DevEco Studio](https://en.wikipedia.org/wiki/DevEco_Studio "DevEco Studio") | | [Haxe](https://en.wikipedia.org/wiki/Haxe "Haxe") | [IntelliJ IDEA](https://en.wikipedia.org/wiki/IntelliJ_IDEA "IntelliJ IDEA") [VS Code](https://en.wikipedia.org/wiki/VS_Code "VS Code") [Sublime Text](https://en.wikipedia.org/wiki/Sublime_Text "Sublime Text") [Powerflasher FDT](https://en.wikipedia.org/wiki/Powerflasher_FDT "Powerflasher FDT") | | [CLI](https://en.wikipedia.org/wiki/Common_Language_Infrastructure "Common Language Infrastructure") ([.NET](https://en.wikipedia.org/wiki/.NET ".NET")) | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") [PascalABC.NET](https://en.wikipedia.org/wiki/PascalABC.NET "PascalABC.NET") | | [Freeware](https://en.wikipedia.org/wiki/Freeware "Freeware") | [Visual Studio Community](https://en.wikipedia.org/wiki/Visual_Studio#Community "Visual Studio") | | [Retail](https://en.wikipedia.org/wiki/Retail_software "Retail software") | [Visual Studio](https://en.wikipedia.org/wiki/Visual_Studio "Visual Studio") [Rider](https://en.wikipedia.org/wiki/JetBrains#Rider "JetBrains") [Understand](https://en.wikipedia.org/wiki/Understand_\(software\) "Understand (software)") | | Discontinued | [Xamarin Studio](https://en.wikipedia.org/wiki/Xamarin_Studio "Xamarin Studio") [MonoDevelop](https://en.wikipedia.org/wiki/MonoDevelop "MonoDevelop") [SharpDevelop](https://en.wikipedia.org/wiki/SharpDevelop "SharpDevelop") [Visual Basic Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#Visual_Basic_Express "Microsoft Visual Studio Express") [Visual Web Developer Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#Visual_Web_Developer_Express "Microsoft Visual Studio Express") [Visual J\# Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#2005%E2%80%932010_products "Microsoft Visual Studio Express") [Visual Studio Express for Windows Phone](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#2005%E2%80%932010_products "Microsoft Visual Studio Express") [Visual C++ Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#Visual_C++_Express "Microsoft Visual Studio Express") [Visual C\# Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#Visual_C#_Express "Microsoft Visual Studio Express") [Express for Desktop](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#2015-2017_products "Microsoft Visual Studio Express") [Express for Web](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#2015-2017_products "Microsoft Visual Studio Express") [Express for Windows](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#2015-2017_products "Microsoft Visual Studio Express") | | [Flash](https://en.wikipedia.org/wiki/Adobe_Flash "Adobe Flash") | [Adobe Flash Builder](https://en.wikipedia.org/wiki/Adobe_Flash_Builder "Adobe Flash Builder") FlashDevelop [Powerflasher FDT](https://en.wikipedia.org/wiki/Powerflasher_FDT "Powerflasher FDT") | | [PHP](https://en.wikipedia.org/wiki/PHP "PHP") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Aptana](https://en.wikipedia.org/wiki/Aptana "Aptana") [NetBeans](https://en.wikipedia.org/wiki/NetBeans "NetBeans") [Komodo Edit](https://en.wikipedia.org/wiki/Komodo_Edit "Komodo Edit") [Komodo IDE](https://en.wikipedia.org/wiki/Komodo_IDE "Komodo IDE") [KDevelop](https://en.wikipedia.org/wiki/KDevelop "KDevelop") | | [Proprietary](https://en.wikipedia.org/wiki/Proprietary_software "Proprietary software") | [Codelobster](https://en.wikipedia.org/wiki/Codelobster "Codelobster") [PhpStorm](https://en.wikipedia.org/wiki/PhpStorm "PhpStorm") [PHPEdit](https://en.wikipedia.org/wiki/PHPEdit "PHPEdit") [SlickEdit](https://en.wikipedia.org/wiki/SlickEdit "SlickEdit") [Zend Studio](https://en.wikipedia.org/wiki/Zend_Studio "Zend Studio") | | [R](https://en.wikipedia.org/wiki/R_\(programming_language\) "R (programming language)") | [RStudio](https://en.wikipedia.org/wiki/RStudio "RStudio") [R Tools for Visual Studio](https://en.wikipedia.org/wiki/R_Tools_for_Visual_Studio "R Tools for Visual Studio") | | [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Anjuta](https://en.wikipedia.org/wiki/Anjuta "Anjuta") [IDLE](https://en.wikipedia.org/wiki/IDLE "IDLE") [Eric](https://en.wikipedia.org/wiki/Eric_\(software\) "Eric (software)") [Light Table](https://en.wikipedia.org/wiki/Light_Table_\(software\) "Light Table (software)") [PyDev](https://en.wikipedia.org/wiki/PyDev "PyDev") PyScripter PIDA [Spyder](https://en.wikipedia.org/wiki/Spyder_\(software\) "Spyder (software)") [Komodo Edit](https://en.wikipedia.org/wiki/Komodo_Edit "Komodo Edit") [Komodo IDE](https://en.wikipedia.org/wiki/Komodo_IDE "Komodo IDE") [KDevelop](https://en.wikipedia.org/wiki/KDevelop "KDevelop") [Vim](https://en.wikipedia.org/wiki/Vim_\(text_editor\) "Vim (text editor)") [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") [Thonny](https://en.wikipedia.org/wiki/Thonny "Thonny") [DevEco Studio](https://en.wikipedia.org/wiki/DevEco_Studio "DevEco Studio") | | [Proprietary](https://en.wikipedia.org/wiki/Proprietary_software "Proprietary software") | [PyCharm](https://en.wikipedia.org/wiki/PyCharm "PyCharm") [PythonAnywhere](https://en.wikipedia.org/wiki/PythonAnywhere "PythonAnywhere") [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") [SlickEdit](https://en.wikipedia.org/wiki/SlickEdit "SlickEdit") [Wing IDE](https://en.wikipedia.org/wiki/Wing_IDE "Wing IDE") | | [Pascal](https://en.wikipedia.org/wiki/Pascal_\(programming_language\) "Pascal (programming language)"), [Object Pascal](https://en.wikipedia.org/wiki/Object_Pascal "Object Pascal") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Free Pascal](https://en.wikipedia.org/wiki/Free_Pascal "Free Pascal") IDE [Lazarus](https://en.wikipedia.org/wiki/Lazarus_\(software\) "Lazarus (software)") [Dev-Pascal](https://en.wikipedia.org/wiki/Dev-Pascal "Dev-Pascal") GNAVI [PascalABC.NET](https://en.wikipedia.org/wiki/PascalABC.NET "PascalABC.NET") | | [Freeware](https://en.wikipedia.org/wiki/Freeware "Freeware") | [Delphi Community](https://en.wikipedia.org/wiki/Delphi_\(software\)#Embarcadero_Delphi_10.2_Tokyo_\(Community_Edition\) "Delphi (software)") | | [Retail](https://en.wikipedia.org/wiki/Retail_software "Retail software") | [Delphi](https://en.wikipedia.org/wiki/Delphi_\(software\) "Delphi (software)") | | Discontinued | [Turbo Pascal](https://en.wikipedia.org/wiki/Turbo_Pascal "Turbo Pascal") [Turbo Delphi](https://en.wikipedia.org/wiki/Turbo_Delphi "Turbo Delphi") [Virtual Pascal](https://en.wikipedia.org/wiki/Virtual_Pascal "Virtual Pascal") [Borland Kylix](https://en.wikipedia.org/wiki/Borland_Kylix "Borland Kylix") [QuickPascal](https://en.wikipedia.org/wiki/Microsoft_Pascal "Microsoft Pascal") | | [BASIC](https://en.wikipedia.org/wiki/BASIC "BASIC") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Basic-256](https://en.wikipedia.org/wiki/Basic-256 "Basic-256") [Microsoft Small Basic](https://en.wikipedia.org/wiki/Microsoft_Small_Basic "Microsoft Small Basic") [SdlBasic](https://en.wikipedia.org/wiki/SdlBasic "SdlBasic") [Gambas](https://en.wikipedia.org/wiki/Gambas "Gambas") [Basic4GL](https://en.wikipedia.org/wiki/Basic4GL "Basic4GL") [VisualFBEditor / WinFBE](https://en.wikipedia.org/wiki/FreeBASIC "FreeBASIC") [InForm](https://en.wikipedia.org/wiki/QB64 "QB64") | | [Freeware](https://en.wikipedia.org/wiki/Freeware "Freeware") | [FutureBASIC](https://en.wikipedia.org/wiki/FutureBASIC "FutureBASIC") [RapidQ](https://en.wikipedia.org/wiki/RapidQ "RapidQ") [Visual Studio Community](https://en.wikipedia.org/wiki/Visual_Studio#Community "Visual Studio") | | [Retail](https://en.wikipedia.org/wiki/Retail_software "Retail software") | [Visual Studio](https://en.wikipedia.org/wiki/Visual_Studio "Visual Studio") [NS Basic](https://en.wikipedia.org/wiki/NS_Basic "NS Basic") [PureBasic](https://en.wikipedia.org/wiki/PureBasic "PureBasic") [GLBasic](https://en.wikipedia.org/wiki/GLBasic "GLBasic") [Liberty BASIC](https://en.wikipedia.org/wiki/Liberty_BASIC "Liberty BASIC") [Xojo](https://en.wikipedia.org/wiki/Xojo "Xojo") | | Discontinued | [CA-Realizer](https://en.wikipedia.org/wiki/CA-Realizer "CA-Realizer") [MonoDevelop](https://en.wikipedia.org/wiki/MonoDevelop "MonoDevelop") [QuickBASIC](https://en.wikipedia.org/wiki/QuickBASIC "QuickBASIC") [QBasic](https://en.wikipedia.org/wiki/QBasic "QBasic") [SharpDevelop](https://en.wikipedia.org/wiki/SharpDevelop "SharpDevelop") [Visual Basic](https://en.wikipedia.org/wiki/Visual_Basic_\(classic\) "Visual Basic (classic)") [Visual Basic Express](https://en.wikipedia.org/wiki/Microsoft_Visual_Studio_Express#Visual_Basic_Express "Microsoft Visual Studio Express") | | [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)") | | | | | | [Open source](https://en.wikipedia.org/wiki/Open-source_software "Open-source software") | [Vim](https://en.wikipedia.org/wiki/Vim_\(text_editor\) "Vim (text editor)") [Visual Studio Code](https://en.wikipedia.org/wiki/Visual_Studio_Code "Visual Studio Code") (VSCode) [Eclipse](https://en.wikipedia.org/wiki/Eclipse_\(software\) "Eclipse (software)") | | [Freeware](https://en.wikipedia.org/wiki/Freeware "Freeware") | [Cloud9 IDE](https://en.wikipedia.org/wiki/Cloud9_IDE "Cloud9 IDE") | | [Retail](https://en.wikipedia.org/wiki/Retail_software "Retail software") | [GoLand](https://en.wikipedia.org/wiki/JetBrains#GoLand "JetBrains") | | [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)") | [RustRover](https://en.wikipedia.org/wiki/JetBrains#RustRover "JetBrains") | | [Eiffel](https://en.wikipedia.org/wiki/Eiffel_\(programming_language\) "Eiffel (programming language)") | [EiffelStudio](https://en.wikipedia.org/wiki/EiffelStudio "EiffelStudio") [LibertyEiffel](https://en.wikipedia.org/wiki/LibertyEiffel "LibertyEiffel") [Visual Eiffel](https://en.wikipedia.org/wiki/Visual_Eiffel "Visual Eiffel") | | [POP-11](https://en.wikipedia.org/wiki/POP-11 "POP-11") | [Poplog](https://en.wikipedia.org/wiki/Poplog "Poplog") | | [Online](https://en.wikipedia.org/wiki/Online_integrated_development_environment "Online integrated development environment") | AWS [Cloud9 IDE](https://en.wikipedia.org/wiki/Cloud9_IDE "Cloud9 IDE") [Eclipse Che](https://en.wikipedia.org/wiki/Eclipse_Che "Eclipse Che") [Firebase Studio](https://en.wikipedia.org/wiki/Firebase_Studio "Firebase Studio") [SourceLair](https://en.wikipedia.org/wiki/SourceLair "SourceLair") | | **[Comparison](https://en.wikipedia.org/wiki/Comparison_of_integrated_development_environments "Comparison of integrated development environments")** **[Category](https://en.wikipedia.org/wiki/Category:Integrated_development_environments "Category:Integrated development environments")** | | | [v](https://en.wikipedia.org/wiki/Template:Programming_languages "Template:Programming languages") [t](https://en.wikipedia.org/wiki/Template_talk:Programming_languages "Template talk:Programming languages") [e](https://en.wikipedia.org/wiki/Special:EditPage/Template:Programming_languages "Special:EditPage/Template:Programming languages")[Programming languages](https://en.wikipedia.org/wiki/Programming_language "Programming language") | |---| | [Comparison](https://en.wikipedia.org/wiki/Comparison_of_programming_languages "Comparison of programming languages") [Timeline](https://en.wikipedia.org/wiki/Timeline_of_programming_languages "Timeline of programming languages") [History](https://en.wikipedia.org/wiki/History_of_programming_languages "History of programming languages") | | [Ada](https://en.wikipedia.org/wiki/Ada_\(programming_language\) "Ada (programming language)") [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") [Simula](https://en.wikipedia.org/wiki/Simula "Simula") [APL](https://en.wikipedia.org/wiki/APL_\(programming_language\) "APL (programming language)") [Assembly](https://en.wikipedia.org/wiki/Assembly_language "Assembly language") [BASIC](https://en.wikipedia.org/wiki/BASIC "BASIC") [Visual Basic](https://en.wikipedia.org/wiki/Visual_Basic "Visual Basic") [classic](https://en.wikipedia.org/wiki/Visual_Basic_\(classic\) "Visual Basic (classic)") [.NET](https://en.wikipedia.org/wiki/Visual_Basic_\(.NET\) "Visual Basic (.NET)") [C]() [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)") [COBOL](https://en.wikipedia.org/wiki/COBOL "COBOL") [Erlang](https://en.wikipedia.org/wiki/Erlang_\(programming_language\) "Erlang (programming language)") [Elixir](https://en.wikipedia.org/wiki/Elixir_\(programming_language\) "Elixir (programming language)") [Forth](https://en.wikipedia.org/wiki/Forth_\(programming_language\) "Forth (programming language)") [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)") [Haskell](https://en.wikipedia.org/wiki/Haskell "Haskell") [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)") [JavaScript](https://en.wikipedia.org/wiki/JavaScript "JavaScript") [Julia](https://en.wikipedia.org/wiki/Julia_\(programming_language\) "Julia (programming language)") [Kotlin](https://en.wikipedia.org/wiki/Kotlin "Kotlin") [Lisp](https://en.wikipedia.org/wiki/Lisp_\(programming_language\) "Lisp (programming language)") [Lua](https://en.wikipedia.org/wiki/Lua "Lua") [MATLAB](https://en.wikipedia.org/wiki/MATLAB "MATLAB") [ML](https://en.wikipedia.org/wiki/ML_\(programming_language\) "ML (programming language)") [Caml](https://en.wikipedia.org/wiki/Caml "Caml") [OCaml](https://en.wikipedia.org/wiki/OCaml "OCaml") [Standard ML](https://en.wikipedia.org/wiki/Standard_ML "Standard ML") [Pascal](https://en.wikipedia.org/wiki/Pascal_\(programming_language\) "Pascal (programming language)") [Object Pascal](https://en.wikipedia.org/wiki/Object_Pascal "Object Pascal") [Perl](https://en.wikipedia.org/wiki/Perl "Perl") [Raku](https://en.wikipedia.org/wiki/Raku_\(programming_language\) "Raku (programming language)") [PHP](https://en.wikipedia.org/wiki/PHP "PHP") [Prolog](https://en.wikipedia.org/wiki/Prolog "Prolog") [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)") [R](https://en.wikipedia.org/wiki/R_\(programming_language\) "R (programming language)") [Ruby](https://en.wikipedia.org/wiki/Ruby_\(programming_language\) "Ruby (programming language)") [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)") [SAS](https://en.wikipedia.org/wiki/SAS_language "SAS language") [SQL](https://en.wikipedia.org/wiki/SQL "SQL") [Scratch](https://en.wikipedia.org/wiki/Scratch_\(programming_language\) "Scratch (programming language)") [Shell](https://en.wikipedia.org/wiki/Shell_script "Shell script") [Smalltalk](https://en.wikipedia.org/wiki/Smalltalk "Smalltalk") [Swift](https://en.wikipedia.org/wiki/Swift_\(programming_language\) "Swift (programming language)") *[more...](https://en.wikipedia.org/wiki/List_of_programming_languages "List of programming languages")* | | ![](https://upload.wikimedia.org/wikipedia/en/thumb/d/db/Symbol_list_class.svg/20px-Symbol_list_class.svg.png) **Lists:** [Alphabetical](https://en.wikipedia.org/wiki/List_of_programming_languages "List of programming languages") [Categorical](https://en.wikipedia.org/wiki/List_of_programming_languages_by_type "List of programming languages by type") [Generational](https://en.wikipedia.org/wiki/Generational_list_of_programming_languages "Generational list of programming languages") [Non-English-based](https://en.wikipedia.org/wiki/Non-English-based_programming_languages "Non-English-based programming languages") ![](https://upload.wikimedia.org/wikipedia/en/thumb/9/96/Symbol_category_class.svg/20px-Symbol_category_class.svg.png) [Category](https://en.wikipedia.org/wiki/Category:Programming_languages "Category:Programming languages") | | [Authority control databases](https://en.wikipedia.org/wiki/Help:Authority_control "Help:Authority control") [![Edit this at Wikidata](https://upload.wikimedia.org/wikipedia/en/thumb/8/8a/OOjs_UI_icon_edit-ltr-progressive.svg/20px-OOjs_UI_icon_edit-ltr-progressive.svg.png)](https://www.wikidata.org/wiki/Q15777#identifiers "Edit this at Wikidata") | | |---|---| | International | [GND](https://d-nb.info/gnd/4113195-2) [FAST](https://id.worldcat.org/fast/843279) | | National | [United States](https://id.loc.gov/authorities/sh85018532) [France](https://catalogue.bnf.fr/ark:/12148/cb119665180) [BnF data](https://data.bnf.fr/ark:/12148/cb119665180) [Czech Republic](https://aleph.nkp.cz/F/?func=find-c&local_base=aut&ccl_term=ica=ph116955&CON_LNG=ENG) [Israel](https://www.nli.org.il/en/authorities/987007293665105171) | | Other | [IdRef](https://www.idref.fr/027672441) [Yale LUX](https://lux.collections.yale.edu/view/concept/7953a614-4dab-469b-8740-221571c086b7) | ![](https://en.wikipedia.org/wiki/Special:CentralAutoLogin/start?useformat=desktop&type=1x1&usesul3=1) Retrieved from "<https://en.wikipedia.org/w/index.php?title=C_(programming_language)&oldid=1345046563>" [Categories](https://en.wikipedia.org/wiki/Help:Category "Help:Category"): - [Software programmed in C](https://en.wikipedia.org/wiki/Category:Software_programmed_in_C "Category:Software programmed in C") - [C (programming language) libraries](https://en.wikipedia.org/wiki/Category:C_\(programming_language\)_libraries "Category:C (programming language) libraries") - [Lists of software](https://en.wikipedia.org/wiki/Category:Lists_of_software "Category:Lists of software") - [Free software programmed in C](https://en.wikipedia.org/wiki/Category:Free_software_programmed_in_C "Category:Free software programmed in C") - [Programming languages](https://en.wikipedia.org/wiki/Category:Programming_languages "Category:Programming languages") - [Software by programming language](https://en.wikipedia.org/wiki/Category:Software_by_programming_language "Category:Software by programming language") - [Mathematical libraries](https://en.wikipedia.org/wiki/Category:Mathematical_libraries "Category:Mathematical libraries") - [C (programming language)](https://en.wikipedia.org/wiki/Category:C_\(programming_language\) "Category:C (programming language)") - [American inventions](https://en.wikipedia.org/wiki/Category:American_inventions "Category:American inventions") - [C programming language family](https://en.wikipedia.org/wiki/Category:C_programming_language_family "Category:C programming language family") - [Cross-platform software](https://en.wikipedia.org/wiki/Category:Cross-platform_software "Category:Cross-platform software") - [High-level programming languages](https://en.wikipedia.org/wiki/Category:High-level_programming_languages "Category:High-level programming languages") - [Procedural programming languages](https://en.wikipedia.org/wiki/Category:Procedural_programming_languages "Category:Procedural programming languages") - [Structured programming languages](https://en.wikipedia.org/wiki/Category:Structured_programming_languages "Category:Structured programming languages") - [Programming languages created in 1972](https://en.wikipedia.org/wiki/Category:Programming_languages_created_in_1972 "Category:Programming languages created in 1972") - [Programming languages with an ISO standard](https://en.wikipedia.org/wiki/Category:Programming_languages_with_an_ISO_standard "Category:Programming languages with an ISO standard") - [Statically typed programming languages](https://en.wikipedia.org/wiki/Category:Statically_typed_programming_languages "Category:Statically typed programming languages") - [Systems programming languages](https://en.wikipedia.org/wiki/Category:Systems_programming_languages "Category:Systems programming languages") - [Compiled programming languages](https://en.wikipedia.org/wiki/Category:Compiled_programming_languages "Category:Compiled programming languages") Hidden categories: - [Webarchive template wayback links](https://en.wikipedia.org/wiki/Category:Webarchive_template_wayback_links "Category:Webarchive template wayback links") - [Articles with short description](https://en.wikipedia.org/wiki/Category:Articles_with_short_description "Category:Articles with short description") - [Short description matches Wikidata](https://en.wikipedia.org/wiki/Category:Short_description_matches_Wikidata "Category:Short description matches Wikidata") - [Wikipedia pending changes protected pages](https://en.wikipedia.org/wiki/Category:Wikipedia_pending_changes_protected_pages "Category:Wikipedia pending changes protected pages") - [Use mdy dates from October 2024](https://en.wikipedia.org/wiki/Category:Use_mdy_dates_from_October_2024 "Category:Use mdy dates from October 2024") - [All articles with vague or ambiguous time](https://en.wikipedia.org/wiki/Category:All_articles_with_vague_or_ambiguous_time "Category:All articles with vague or ambiguous time") - [Vague or ambiguous time from August 2022](https://en.wikipedia.org/wiki/Category:Vague_or_ambiguous_time_from_August_2022 "Category:Vague or ambiguous time from August 2022") - [Wikipedia articles in need of updating from February 2021](https://en.wikipedia.org/wiki/Category:Wikipedia_articles_in_need_of_updating_from_February_2021 "Category:Wikipedia articles in need of updating from February 2021") - [All Wikipedia articles in need of updating](https://en.wikipedia.org/wiki/Category:All_Wikipedia_articles_in_need_of_updating "Category:All Wikipedia articles in need of updating") - [Articles needing additional references from October 2012](https://en.wikipedia.org/wiki/Category:Articles_needing_additional_references_from_October_2012 "Category:Articles needing additional references from October 2012") - [All articles needing additional references](https://en.wikipedia.org/wiki/Category:All_articles_needing_additional_references "Category:All articles needing additional references") - [Wikipedia articles needing clarification from October 2021](https://en.wikipedia.org/wiki/Category:Wikipedia_articles_needing_clarification_from_October_2021 "Category:Wikipedia articles needing clarification from October 2021") - [All articles lacking reliable references](https://en.wikipedia.org/wiki/Category:All_articles_lacking_reliable_references "Category:All articles lacking reliable references") - [Articles lacking reliable references from August 2025](https://en.wikipedia.org/wiki/Category:Articles_lacking_reliable_references_from_August_2025 "Category:Articles lacking reliable references from August 2025") - [All articles with unsourced statements](https://en.wikipedia.org/wiki/Category:All_articles_with_unsourced_statements "Category:All articles with unsourced statements") - [Articles with unsourced statements from August 2025](https://en.wikipedia.org/wiki/Category:Articles_with_unsourced_statements_from_August_2025 "Category:Articles with unsourced statements from August 2025") - [Pages using Sister project links with wikidata mismatch](https://en.wikipedia.org/wiki/Category:Pages_using_Sister_project_links_with_wikidata_mismatch "Category:Pages using Sister project links with wikidata mismatch") - [Pages using Sister project links with hidden wikidata](https://en.wikipedia.org/wiki/Category:Pages_using_Sister_project_links_with_hidden_wikidata "Category:Pages using Sister project links with hidden wikidata") - [Articles with example C code](https://en.wikipedia.org/wiki/Category:Articles_with_example_C_code "Category:Articles with example C code") - This page was last edited on 24 March 2026, at 00:55 (UTC). - Text is available under the [Creative Commons Attribution-ShareAlike 4.0 License](https://en.wikipedia.org/wiki/Wikipedia:Text_of_the_Creative_Commons_Attribution-ShareAlike_4.0_International_License "Wikipedia:Text of the Creative Commons Attribution-ShareAlike 4.0 International License"); additional terms may apply. By using this site, you agree to the [Terms of Use](https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Terms_of_Use "foundation:Special:MyLanguage/Policy:Terms of Use") and [Privacy Policy](https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Privacy_policy "foundation:Special:MyLanguage/Policy:Privacy policy"). Wikipedia® is a registered trademark of the [Wikimedia Foundation, Inc.](https://wikimediafoundation.org/), a non-profit organization. - [Privacy policy](https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Privacy_policy) - [About Wikipedia](https://en.wikipedia.org/wiki/Wikipedia:About) - [Disclaimers](https://en.wikipedia.org/wiki/Wikipedia:General_disclaimer) - [Contact Wikipedia](https://en.wikipedia.org/wiki/Wikipedia:Contact_us) - [Legal & safety contacts](https://foundation.wikimedia.org/wiki/Special:MyLanguage/Legal:Wikimedia_Foundation_Legal_and_Safety_Contact_Information) - [Code of Conduct](https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Universal_Code_of_Conduct) - [Developers](https://developer.wikimedia.org/) - [Statistics](https://stats.wikimedia.org/#/en.wikipedia.org) - [Cookie statement](https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Cookie_statement) - [Mobile view](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&mobileaction=toggle_view_mobile) - [![Wikimedia Foundation](https://en.wikipedia.org/static/images/footer/wikimedia.svg)](https://www.wikimedia.org/) - [![Powered by MediaWiki](https://en.wikipedia.org/w/resources/assets/mediawiki_compact.svg)](https://www.mediawiki.org/) Search Toggle the table of contents C (programming language) 125 languages [Add topic](https://en.wikipedia.org/wiki/C_\(programming_language\))
Readable Markdown
"C lang" redirects here. For the compiler front end, see [Clang](https://en.wikipedia.org/wiki/Clang "Clang"). Not to be confused with [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") or [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)"). | C | | |---|---| | [![](https://upload.wikimedia.org/wikipedia/commons/thumb/3/35/The_C_Programming_Language_logo.svg/250px-The_C_Programming_Language_logo.svg.png)](https://en.wikipedia.org/wiki/File:The_C_Programming_Language_logo.svg)Logotype used on the cover of the first edition of *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*[\[1\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-C_in_a_Nutshell-1) | | | [Paradigm](https://en.wikipedia.org/wiki/Programming_paradigm "Programming paradigm") | [Multi-paradigm](https://en.wikipedia.org/wiki/Multi-paradigm "Multi-paradigm"): [imperative](https://en.wikipedia.org/wiki/Imperative_programming "Imperative programming") ([procedural](https://en.wikipedia.org/wiki/Procedural_programming "Procedural programming")), [structured](https://en.wikipedia.org/wiki/Structured_programming "Structured programming") | | [Designed by](https://en.wikipedia.org/wiki/Software_design "Software design") | [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") | | [Developer](https://en.wikipedia.org/wiki/Software_developer "Software developer") | ANSI X3J11 ([ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C")); [ISO/IEC JTC 1 (Joint Technical Committee 1) / SC 22 (Subcommittee 22)](https://en.wikipedia.org/wiki/ISO/IEC_JTC_1/SC_22 "ISO/IEC JTC 1/SC 22") / WG 14 (Working Group 14) (ISO C) | | First appeared | 1972; 54 years ago[\[a\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-5) | | [Stable release](https://en.wikipedia.org/wiki/Software_release_life_cycle "Software release life cycle") | [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)") / October 31, 2024; 17 months ago | | [Preview release](https://en.wikipedia.org/wiki/Software_release_life_cycle#Beta "Software release life cycle") | [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") (N3220) / February 21, 2024; 2 years ago[\[5\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-6) | | [Typing discipline](https://en.wikipedia.org/wiki/Type_system "Type system") | [Static](https://en.wikipedia.org/wiki/Type_system "Type system"), [weak](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"), [manifest](https://en.wikipedia.org/wiki/Manifest_typing "Manifest typing"), [nominal](https://en.wikipedia.org/wiki/Nominal_type_system "Nominal type system") | | [OS](https://en.wikipedia.org/wiki/Operating_system "Operating system") | [Cross-platform](https://en.wikipedia.org/wiki/Cross-platform "Cross-platform") | | [Filename extensions](https://en.wikipedia.org/wiki/Filename_extension "Filename extension") | .c, .h | | Website | [c-language.org](https://www.c-language.org/) [iso.org](https://www.iso.org/standard/82075.html) [open-std.org](https://www.open-std.org/jtc1/sc22/wg14/) | | Major [implementations](https://en.wikipedia.org/wiki/Programming_language_implementation "Programming language implementation") | | | [pcc](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler"), [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection"), [Clang](https://en.wikipedia.org/wiki/Clang "Clang"), [Intel C](https://en.wikipedia.org/wiki/Intel_C%2B%2B_Compiler "Intel C++ Compiler"), [C++Builder](https://en.wikipedia.org/wiki/C%2B%2BBuilder "C++Builder"), [Microsoft Visual C++](https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B "Microsoft Visual C++"), [Watcom C](https://en.wikipedia.org/wiki/Watcom_C/C%2B%2B "Watcom C/C++") | | | [Dialects](https://en.wikipedia.org/wiki/Programming_language#Dialects,_flavors_and_implementations "Programming language") | | | [Cyclone](https://en.wikipedia.org/wiki/Cyclone_\(programming_language\) "Cyclone (programming language)"), [Unified Parallel C](https://en.wikipedia.org/wiki/Unified_Parallel_C "Unified Parallel C"), [Split-C](https://en.wikipedia.org/wiki/Split-C "Split-C"), [Cilk](https://en.wikipedia.org/wiki/Cilk "Cilk"), [C\*](https://en.wikipedia.org/wiki/C* "C*") | | | Influenced by | | | [B](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)"), [BCPL](https://en.wikipedia.org/wiki/BCPL "BCPL"), [CPL](https://en.wikipedia.org/wiki/CPL_\(programming_language\) "CPL (programming language)"), [ALGOL 68](https://en.wikipedia.org/wiki/ALGOL_68 "ALGOL 68"),[\[b\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-9) [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I"), [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") | | | Influenced | | | [Numerous](https://en.wikipedia.org/wiki/Category:C_programming_language_family "Category:C programming language family"): [AMPL](https://en.wikipedia.org/wiki/AMPL "AMPL"), [AWK](https://en.wikipedia.org/wiki/AWK "AWK"), [csh](https://en.wikipedia.org/wiki/C_shell "C shell"), [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++"), [C--](https://en.wikipedia.org/wiki/C-- "C--"), [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)"), [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C"), [D](https://en.wikipedia.org/wiki/D_\(programming_language\) "D (programming language)"), [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)"), [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)"), [JavaScript](https://en.wikipedia.org/wiki/JavaScript "JavaScript"), [JS++](https://en.wikipedia.org/wiki/JS%2B%2B "JS++"), [Julia](https://en.wikipedia.org/wiki/Julia_\(programming_language\) "Julia (programming language)"), [Limbo](https://en.wikipedia.org/wiki/Limbo_\(programming_language\) "Limbo (programming language)"), [LPC](https://en.wikipedia.org/wiki/LPC_\(programming_language\) "LPC (programming language)"), [Perl](https://en.wikipedia.org/wiki/Perl "Perl"), [PHP](https://en.wikipedia.org/wiki/PHP "PHP"), [Pike](https://en.wikipedia.org/wiki/Pike_\(programming_language\) "Pike (programming language)"), [Processing](https://en.wikipedia.org/wiki/Processing_\(programming_language\) "Processing (programming language)"), [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)"), [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)"), [V (Vlang)](https://en.wikipedia.org/wiki/V_\(programming_language\) "V (programming language)"), [Vala](https://en.wikipedia.org/wiki/Vala_\(programming_language\) "Vala (programming language)"), [Verilog](https://en.wikipedia.org/wiki/Verilog "Verilog") (HDL),[\[8\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-vinsp-10) [Nim](https://en.wikipedia.org/wiki/Nim_\(programming_language\) "Nim (programming language)"), [Zig](https://en.wikipedia.org/wiki/Zig_\(programming_language\) "Zig (programming language)") | | | [![Wikibooks logo](https://upload.wikimedia.org/wikipedia/commons/thumb/f/fa/Wikibooks-logo.svg/20px-Wikibooks-logo.svg.png)](https://en.wikipedia.org/wiki/File:Wikibooks-logo.svg) [C Programming](https://en.wikibooks.org/wiki/C_Programming "wikibooks:C Programming") at Wikibooks | | **C**[\[c\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-12) is a [general-purpose programming language](https://en.wikipedia.org/wiki/General-purpose_programming_language "General-purpose programming language") created in the 1970s by [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie"). By design, C gives the [programmer](https://en.wikipedia.org/wiki/Programmer "Programmer") relatively direct access to the features of the typical [CPU](https://en.wikipedia.org/wiki/Central_processing_unit "Central processing unit") architecture, customized for the target [instruction set](https://en.wikipedia.org/wiki/Instruction_set_architecture "Instruction set architecture"). It has been and continues to be used to implement [operating systems](https://en.wikipedia.org/wiki/Operating_system "Operating system") (especially [kernels](https://en.wikipedia.org/wiki/Kernel_\(operating_system\) "Kernel (operating system)")[\[10\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-13)), [device drivers](https://en.wikipedia.org/wiki/Device_driver "Device driver"), and [protocol stacks](https://en.wikipedia.org/wiki/Protocol_stack "Protocol stack"), but its use in [application software](https://en.wikipedia.org/wiki/Application_software "Application software") has been decreasing.[\[11\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-14) C is used on computers that range from the largest [supercomputers](https://en.wikipedia.org/wiki/Supercomputer "Supercomputer") to the smallest [microcontrollers](https://en.wikipedia.org/wiki/Microcontroller "Microcontroller") and [embedded systems](https://en.wikipedia.org/wiki/Embedded_system "Embedded system"). A successor to the programming language [B](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)"), C was originally developed at [Bell Labs](https://en.wikipedia.org/wiki/Bell_Labs "Bell Labs") by Ritchie between 1972 and 1973 to construct utilities running on [Unix](https://en.wikipedia.org/wiki/Unix "Unix"). It was applied to re-implementing the kernel of the Unix operating system.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) During the 1980s, C gradually gained popularity. It has become one of the most widely used [programming languages](https://en.wikipedia.org/wiki/Programming_language "Programming language"),[\[13\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-langpop-16)[\[14\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-TIOBE-2009-17) with C [compilers](https://en.wikipedia.org/wiki/Compiler "Compiler") available for practically all modern [computer architectures](https://en.wikipedia.org/wiki/Computer_architecture "Computer architecture") and [operating systems](https://en.wikipedia.org/wiki/Operating_system "Operating system"). The book *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*, co-authored by the original language designer, served for many years as the *de facto* standard for the language.[\[15\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-ward198308-18)[\[1\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-C_in_a_Nutshell-1) C has been standardized since 1989 by the [American National Standards Institute](https://en.wikipedia.org/wiki/American_National_Standards_Institute "American National Standards Institute") (ANSI) and, subsequently, jointly by the [International Organization for Standardization](https://en.wikipedia.org/wiki/International_Organization_for_Standardization "International Organization for Standardization") (ISO) and the [International Electrotechnical Commission](https://en.wikipedia.org/wiki/International_Electrotechnical_Commission "International Electrotechnical Commission") (IEC). C is an [imperative](https://en.wikipedia.org/wiki/Imperative_programming "Imperative programming") [procedural](https://en.wikipedia.org/wiki/Procedural_programming "Procedural programming") language, supporting [structured programming](https://en.wikipedia.org/wiki/Structured_programming "Structured programming"), [lexical variable scope](https://en.wikipedia.org/wiki/Lexical_variable_scope "Lexical variable scope"), and [recursion](https://en.wikipedia.org/wiki/Recursion_\(computer_science\) "Recursion (computer science)"), with a [static type system](https://en.wikipedia.org/wiki/Static_type_system "Static type system"). It was designed to be [compiled](https://en.wikipedia.org/wiki/Compiled "Compiled") to provide [low-level](https://en.wikipedia.org/wiki/Low-level_programming_language "Low-level programming language") access to [memory](https://en.wikipedia.org/wiki/Computer_memory "Computer memory") and language constructs that map efficiently to [machine instructions](https://en.wikipedia.org/wiki/Machine_instructions "Machine instructions"), all with minimal [runtime support](https://en.wikipedia.org/wiki/Runtime_system "Runtime system"). Despite its low-level capabilities, the language was designed to encourage cross-platform programming. A [standards](https://en.wikipedia.org/wiki/Specification_\(technical_standard\) "Specification (technical standard)")\-compliant C program written with [portability](https://en.wikipedia.org/wiki/Software_portability "Software portability") in mind can be compiled for a wide variety of computer platforms and operating systems with few changes to its source code. Although neither C nor its standard library provide some popular features found in other languages, it is flexible enough to support them. For example, [object orientation](https://en.wikipedia.org/wiki/Object-oriented_programming "Object-oriented programming") and [garbage collection](https://en.wikipedia.org/wiki/Garbage_collection_\(computer_science\) "Garbage collection (computer science)") are provided by external libraries [GLib Object System](https://en.wikipedia.org/wiki/GLib_Object_System "GLib Object System") and [Boehm garbage collector](https://en.wikipedia.org/wiki/Boehm_garbage_collector "Boehm garbage collector"), respectively. Since 2000, C has typically ranked as the most or second-most popular language in the [TIOBE index](https://en.wikipedia.org/wiki/TIOBE_index "TIOBE index").[\[16\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-19) [![](https://upload.wikimedia.org/wikipedia/commons/thumb/1/1b/Ken_Thompson_and_Dennis_Ritchie--1973.jpg/250px-Ken_Thompson_and_Dennis_Ritchie--1973.jpg)](https://en.wikipedia.org/wiki/File:Ken_Thompson_and_Dennis_Ritchie--1973.jpg) [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (right), the inventor of the C programming language, with [Ken Thompson](https://en.wikipedia.org/wiki/Ken_Thompson "Ken Thompson") The C language exhibits the following characteristics: - [Free-form](https://en.wikipedia.org/wiki/Free-form_language "Free-form language") source code - [Semicolons](https://en.wikipedia.org/wiki/Semicolon "Semicolon") terminate [statements](https://en.wikipedia.org/wiki/Statement_\(programming\) "Statement (programming)") - [Curly braces](https://en.wikipedia.org/wiki/Curly_braces "Curly braces") group statements into [blocks](https://en.wikipedia.org/wiki/Block_\(programming\) "Block (programming)") - [Executable code](https://en.wikipedia.org/wiki/Executable_code "Executable code") is contained in [functions](https://en.wikipedia.org/wiki/Function_\(computer_programming\) "Function (computer programming)") (no script-like syntax) - [Parameters](https://en.wikipedia.org/wiki/Function_parameter "Function parameter") are passed by value; pass by-reference is achieved by passing a pointer to a value - Relatively small number of keywords - [Control flow](https://en.wikipedia.org/wiki/Control_flow "Control flow") constructs, including `if`, `for`, `do`, `while`, and `switch` - [Arithmetic](https://en.wikipedia.org/wiki/Arithmetic "Arithmetic"), [bitwise](https://en.wikipedia.org/wiki/Bitwise "Bitwise"), and logic operators, including `+`,`+=`,`++`,`&`,`||` - Multiple [assignments](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)") may be performed in a single statement - User-defined identifiers are not distinguished from keywords (i.e., by a [sigil](https://en.wikipedia.org/wiki/Sigil_\(computer_programming\) "Sigil (computer programming)")) - A variable declared inside a block is accessible only in that block and only below the declaration - A function return value can be ignored - A function cannot be nested inside a function, but some translators support this - [Run-time polymorphism](https://en.wikipedia.org/wiki/Run-time_polymorphism "Run-time polymorphism") may be achieved using function pointers - Supports [recursion](https://en.wikipedia.org/wiki/Recursion_\(computer_science\) "Recursion (computer science)") - Data typing is [static](https://en.wikipedia.org/wiki/Static_typing "Static typing"), but [weakly enforced](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"); all variables have a type, but [implicit conversion](https://en.wikipedia.org/wiki/Implicit_conversion "Implicit conversion") between primitive types weakens the separation of the different types - [User-defined](https://en.wikipedia.org/wiki/Typedef "Typedef") data types allow for aliasing a data type specifier - Syntax for [array](https://en.wikipedia.org/wiki/Array_\(data_type\) "Array (data type)") definition and access is via square bracket notation, for example `month[11]`. Indexing is defined in terms of pointer arithmetic. Whole arrays cannot be copied or compared without custom or library code - User-defined [structure](https://en.wikipedia.org/wiki/Struct_\(C_programming_language\) "Struct (C programming language)") types allow related data elements to be passed and copied as a unit although two structures cannot be compared without custom code to compare each field - User-defined [union](https://en.wikipedia.org/wiki/Union_type "Union type") types support overlapping members, allowing multiple data types to share the same [memory location](https://en.wikipedia.org/wiki/Memory_location "Memory location") - User-defined [enumeration](https://en.wikipedia.org/wiki/Enumerated_type "Enumerated type") types support aliasing integer values - Lacks a [string type](https://en.wikipedia.org/wiki/String_\(computer_science\) "String (computer science)") but has syntax for [null-terminated strings](https://en.wikipedia.org/wiki/Null-terminated_string "Null-terminated string") with associated [handling](https://en.wikipedia.org/wiki/C_string_handling "C string handling") in its standard library - Supports low-level access to [computer memory](https://en.wikipedia.org/wiki/Computer_memory "Computer memory") via [pointers](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)") - Supports [procedure-like](https://en.wikipedia.org/wiki/Procedure_\(computer_science\) "Procedure (computer science)") construct as a function returning `void` - Supports [dynamic memory](https://en.wikipedia.org/wiki/Dynamic_allocation "Dynamic allocation") via standard library functions - Includes the [C preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") to perform [macro](https://en.wikipedia.org/wiki/Macro_\(computer_science\) "Macro (computer science)") definition, [source code](https://en.wikipedia.org/wiki/Source_code "Source code") file inclusion, and [conditional compilation](https://en.wikipedia.org/wiki/Conditional_compilation "Conditional compilation") - Supports [modularity](https://en.wikipedia.org/wiki/Modular_programming "Modular programming") in that files are processed separately, with visibility control via `static` and `extern` attributes - Minimized functionality in the core language while relatively complex functionality such as [I/O](https://en.wikipedia.org/wiki/Input/output "Input/output"), string manipulation, and mathematical functions supported via standard library functions - Resulting compiled code has relatively straightforward needs on the underlying platform, making it desirable for operating and [embedded](https://en.wikipedia.org/wiki/Embedded_system "Embedded system") systems ## "Hello, world" example \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=2 "Edit section: \"Hello, world\" example")\] [![](https://upload.wikimedia.org/wikipedia/commons/thumb/2/21/Hello_World_Brian_Kernighan_1978.jpg/250px-Hello_World_Brian_Kernighan_1978.jpg)](https://en.wikipedia.org/wiki/File:Hello_World_Brian_Kernighan_1978.jpg) "Hello, World!" program by [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan") (1978) The ["Hello, World!" program](https://en.wikipedia.org/wiki/%22Hello,_World!%22_program "\"Hello, World!\" program") example that appeared in the first edition of *[K\&R](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")* has become the model for an introductory program in most programming textbooks. The program prints "hello, world" to the [standard output](https://en.wikipedia.org/wiki/Standard_output "Standard output"). The original version was:[\[17\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie19786-20) ``` main() { printf("hello, world\n"); } ``` A more modern version is:[\[d\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-21) ``` #include <stdio.h> int main(void) { printf("hello, world\n"); } ``` The first line is a [preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") [directive](https://en.wikipedia.org/wiki/Directive_\(programming\) "Directive (programming)"), indicated by `#include`, which causes the preprocessor to replace that line of code with the text of the `stdio.h` header file, which contains declarations for input and output functions including `printf`. The angle brackets around `stdio.h` indicate that the header file can be located using a search strategy that selects header files provided with the compiler over files with the same name that may be found in project-specific directories. The next code line declares the [entry point](https://en.wikipedia.org/wiki/Entry_point "Entry point") function `main`. The [run-time environment](https://en.wikipedia.org/wiki/Run-time_environment "Run-time environment") calls this function to begin program execution. The type specifier `int` indicates that the function returns an integer value. The `void` parameter list indicates that the function consumes no arguments. The run-time environment actually passes two arguments (typed `int` and `char *[]`), but this implementation ignores them. The ISO C standard (section 5.1.2.2.1) requires syntax that either is void or these two arguments – a special treatment not afforded to other functions. The opening curly brace indicates the beginning of the code that defines the function. The next line of code calls (diverts execution to) the C standard library function `printf` with the [address](https://en.wikipedia.org/wiki/Memory_address "Memory address") of the first character of a null-terminated string specified as a [string literal](https://en.wikipedia.org/wiki/String_literal "String literal"). The text `\n` is an [escape sequence](https://en.wikipedia.org/wiki/Escape_sequence "Escape sequence") that denotes the [newline](https://en.wikipedia.org/wiki/Newline "Newline") character which when output in a terminal results in moving the cursor to the beginning of the next line. Even though `printf` returns an `int` value, it is silently discarded. The semicolon `;` terminates the call statement. The closing curly brace indicates the end of the `main` function. Prior to C99, an explicit `return 0;` statement was required at the end of `main` function, but since C99, the `main` function (as being the initial function call) implicitly returns `0` upon reaching its final closing curly brace.[\[e\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-23) | Year | Informal name | Official standard | |---|---|---| | 1972 | first release | N/a | | 1978 | [K\&R C](https://en.wikipedia.org/wiki/K%26R_C "K&R C") | N/a | | 1989, 1990 | [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C"), C89, ISO C, C90 | ANSI X3.159-1989 ISO/IEC 9899:1990 | | 1999 | [C99](https://en.wikipedia.org/wiki/C99 "C99"), C9X | ISO/IEC 9899:1999 | | 2011 | [C11](https://en.wikipedia.org/wiki/C11_\(C_standard_revision\) "C11 (C standard revision)"), C1X | ISO/IEC 9899:2011 | | 2018 | [C17](https://en.wikipedia.org/wiki/C17_\(C_standard_revision\) "C17 (C standard revision)"), C18 | ISO/IEC 9899:2018 | | 2024 | [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)"), C2X | ISO/IEC 9899:2024 | | TBA | [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") | | The origin of C is closely tied to the development of the [Unix](https://en.wikipedia.org/wiki/Unix "Unix") operating system, originally implemented in [assembly language](https://en.wikipedia.org/wiki/Assembly_language "Assembly language") on a [PDP-7](https://en.wikipedia.org/wiki/PDP-7 "PDP-7") by [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") and [Ken Thompson](https://en.wikipedia.org/wiki/Ken_Thompson "Ken Thompson"), incorporating several ideas from colleagues. Eventually, they decided to port the operating system to a [PDP-11](https://en.wikipedia.org/wiki/PDP-11 "PDP-11"). The original PDP-11 version of Unix was also developed in assembly language.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) Thompson wanted a programming language for developing utilities for the new platform. He first tried writing a [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") compiler, but he soon gave up the idea and instead created a cut-down version of the recently developed [systems programming language](https://en.wikipedia.org/wiki/Systems_programming_language "Systems programming language") called [BCPL](https://en.wikipedia.org/wiki/BCPL "BCPL"). The official description of BCPL was not available at the time,[\[19\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-NFDsZ-24) and Thompson modified the syntax to be less 'wordy' and similar to a simplified [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") known as SMALGOL.[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) He called the result [*B*](https://en.wikipedia.org/wiki/B_\(programming_language\) "B (programming language)"),[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) describing it as "BCPL semantics with a lot of SMALGOL syntax".[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) Like BCPL, B had a [bootstrapping](https://en.wikipedia.org/wiki/Bootstrapping "Bootstrapping") compiler to facilitate porting to new machines.[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) Ultimately, few utilities were written in B because it was too slow and could not take advantage of PDP-11 features such as [byte](https://en.wikipedia.org/wiki/Byte "Byte") addressability. Unlike BCPL's `// comment` marking comments up to the end of the line, B adopted `/* comment */` as the comment delimiter, more akin to PL/1, and allowing comments to appear in the middle of lines. (BCPL's comment style would be reintroduced in C++.)[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) #### New B and first C release \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=6 "Edit section: New B and first C release")\] In 1971 Ritchie started to improve B, to use the features of the more-powerful PDP-11. A significant addition was a character data type. He called this *New B* (NB).[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25) Thompson started to use NB to write the [Unix](https://en.wikipedia.org/wiki/Research_Unix "Research Unix") kernel, and his requirements shaped the direction of the language development.[\[20\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Ars-25)[\[21\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-unixport-26) Through to 1972, richer types were added to the NB language. NB had arrays of `int` and `char`, and to these types were added pointers, the ability to generate pointers to other types, arrays of all types, and types to be returned from functions. Arrays within expressions were effectively treated as pointers. A new compiler was written, and the language was renamed C.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) The C compiler and some utilities made with it were included in [Version 2 Unix](https://en.wikipedia.org/wiki/Version_2_Unix "Version 2 Unix"), which is also known as [Research Unix](https://en.wikipedia.org/wiki/Research_Unix "Research Unix").[\[22\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-QtqTh-27) #### Structures and Unix kernel re-write \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=7 "Edit section: Structures and Unix kernel re-write")\] At [Version 4 Unix](https://en.wikipedia.org/wiki/Version_4_Unix "Version 4 Unix"), released in November 1973, the [Unix](https://en.wikipedia.org/wiki/Unix "Unix") [kernel](https://en.wikipedia.org/wiki/Kernel_\(operating_system\) "Kernel (operating system)") was extensively re-implemented in C.[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) By this time, the C language had acquired some powerful features such as `struct` types. The [preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") was introduced around 1973 at the urging of [Alan Snyder](https://en.wikipedia.org/w/index.php?title=Alan_Snyder_\(computer_scientist\)&action=edit&redlink=1 "Alan Snyder (computer scientist) (page does not exist)") and also in recognition of the usefulness of the file-inclusion mechanisms available in BCPL and [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I"). Its original version provided only included files and simple string replacements: `#include` and `#define` of parameterless macros. Soon after that, it was extended, mostly by [Mike Lesk](https://en.wikipedia.org/wiki/Mike_Lesk "Mike Lesk") and then by John Reiser, to incorporate macros with arguments and [conditional compilation](https://en.wikipedia.org/wiki/Conditional_compilation "Conditional compilation").[\[12\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a-15) Unix was one of the first operating system kernels implemented in a language other than [assembly](https://en.wikipedia.org/wiki/Assembly_language "Assembly language"). Earlier instances include the [Multics](https://en.wikipedia.org/wiki/Multics "Multics") system (which was written in [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I")) and [Master Control Program](https://en.wikipedia.org/wiki/Master_Control_Program "Master Control Program") (MCP) for the [Burroughs B5000](https://en.wikipedia.org/wiki/Burroughs_large_systems "Burroughs large systems") (which was written in [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL")) in 1961. In and around 1977, Ritchie and [Stephen C. Johnson](https://en.wikipedia.org/wiki/Stephen_C._Johnson "Stephen C. Johnson") made further changes to the language to facilitate [portability](https://en.wikipedia.org/wiki/Software_portability "Software portability") of the Unix operating system. Johnson's [Portable C Compiler](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler") served as the basis for several implementations of C on new platforms.[\[21\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-unixport-26) [![](https://upload.wikimedia.org/wikipedia/commons/thumb/0/0e/The_C_Programming_Language%2C_First_Edition_Cover.svg/250px-The_C_Programming_Language%2C_First_Edition_Cover.svg.png)](https://en.wikipedia.org/wiki/File:The_C_Programming_Language,_First_Edition_Cover.svg) The cover of the book *The C Programming Language*, first edition, by [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan") and [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") In 1978 [Brian Kernighan](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan") and [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") published the first edition of *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*.[\[23\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1978-28) Known as *K\&R* from the initials of its authors, the book served for many years as an informal [specification](https://en.wikipedia.org/wiki/Specification_\(technical_standard\) "Specification (technical standard)") of the language. The version of C that it describes is commonly referred to as "**K\&R C**". As this was released in 1978, it is now also referred to as *C78*.[\[24\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-qOvzA-29) The second edition of the book[\[25\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988-30) covers the later [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C") standard, described below. *K\&R* introduced several language features: - [Standard I/O library](https://en.wikipedia.org/wiki/C_file_input/output "C file input/output") - `long int` data type - `unsigned int` data type - Compound assignment operators of the form `=op` (such as `=-`) were changed to the form `op=` (that is, `-=`) to remove the semantic ambiguity created by constructs such as `i=-10`, which had been interpreted as `i =- 10` (decrement `i` by 10) instead of the possibly intended `i = -10` (let `i` be −10). Even after the publication of the 1989 ANSI standard, for many years K\&R C was still considered the "[lowest common denominator](https://en.wikipedia.org/wiki/Lowest_common_denominator_\(computers\) "Lowest common denominator (computers)")" to which C programmers restricted themselves when maximum portability was desired, since many older compilers were still in use, and because carefully written K\&R C code can be legal Standard C as well. Although later versions of C require functions to have an explicit type declaration, K\&R C only requires functions that return a type other than `int` to be declared before use. Functions used without prior declaration were presumed to return `int`. For example: ``` long long_function(); calling_function() { long longvar; register intvar; longvar = long_function(); if (longvar > 1) intvar = 0; else intvar = int_function(); return intvar; } ``` The declaration of `long_function()` (on line 1) is required since it returns `long`; not `int`. Function `int_function` can be called (line 11) even though it is not declared since it returns `int`. Also, variable `intvar` does not need to be declared as type `int` since that is the default type for `register` keyword. Since function declarations did not include information about arguments, [type checks](https://en.wikipedia.org/wiki/Type_checking "Type checking") were not performed, although some compilers would issue a warning if different calls to a function used different numbers or types of arguments. Tools such as Unix's [lint](https://en.wikipedia.org/wiki/Lint_programming_tool "Lint programming tool") utility were developed that (among other things) checked for consistency of function use across multiple source files. In the years following the publication of K\&R C, several features were added to the language, supported by compilers from AT\&T (in particular [PCC](https://en.wikipedia.org/wiki/Portable_C_Compiler "Portable C Compiler")[\[26\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-SkKfZ-31)) and other vendors. These included: - `void` functions; functions returning no value - Functions returning `struct` or `union` types - [Assignment](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)") for `struct` variables - [Enumerated types](https://en.wikipedia.org/wiki/Enumerated_type "Enumerated type") The popularity of the language, lack of agreement on [standard library](https://en.wikipedia.org/wiki/C_standard_library "C standard library") interfaces, and lack of compliance to the K\&R specification, led to standardization efforts.[\[27\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-32) During the late 1970s and 1980s, versions of C were implemented for a wide variety of [mainframe computers](https://en.wikipedia.org/wiki/Mainframe_computer "Mainframe computer"), [minicomputers](https://en.wikipedia.org/wiki/Minicomputer "Minicomputer"), and [microcomputers](https://en.wikipedia.org/wiki/Microcomputer "Microcomputer"), including the [IBM PC](https://en.wikipedia.org/wiki/IBM_PC "IBM PC"), as its popularity increased significantly. In 1983 the [American National Standards Institute](https://en.wikipedia.org/wiki/American_National_Standards_Institute "American National Standards Institute") (ANSI) formed a committee, X3J11, to establish a standard specification of C. X3J11 based the C standard on the Unix implementation; however, the non-portable portion of the Unix C library was handed off to the [IEEE](https://en.wikipedia.org/wiki/IEEE "IEEE") [working group](https://en.wikipedia.org/wiki/Working_group "Working group") 1003 to become the basis for the 1988 [POSIX](https://en.wikipedia.org/wiki/POSIX "POSIX") standard. In 1989, the C standard was ratified as ANSI X3.159-1989 "Programming Language C". This version of the language is often referred to as [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C"), Standard C, or sometimes **C89**. In 1990 the ANSI C standard (with formatting changes) was adopted by the [International Organization for Standardization](https://en.wikipedia.org/wiki/International_Organization_for_Standardization "International Organization for Standardization") (ISO) as ISO/IEC 9899:1990, which is sometimes called **C90**. Therefore, the terms "C89" and "C90" refer to the same programming language. ANSI, like other national standards bodies, no longer develops the C standard independently, but defers to the international C standard, maintained by the working group [ISO/IEC JTC1/SC22](https://en.wikipedia.org/wiki/ISO/IEC_JTC1/SC22 "ISO/IEC JTC1/SC22")/WG14. National adoption of an update to the international standard typically occurs within a year of ISO publication. One of the aims of the C standardization process was to produce a [superset](https://en.wikipedia.org/wiki/Superset "Superset") of K\&R C, incorporating many of the subsequently introduced unofficial features. The standards committee also included several additional features such as [function prototypes](https://en.wikipedia.org/wiki/Function_prototype "Function prototype") (borrowed from C++), `void` pointers, support for international [character sets](https://en.wikipedia.org/wiki/Character_sets "Character sets") and [locales](https://en.wikipedia.org/wiki/Locale_\(computer_software\) "Locale (computer software)"), and preprocessor enhancements. Although the [syntax](https://en.wikipedia.org/wiki/C_syntax "C syntax") for parameter declarations was augmented to include the style used in C++, the K\&R interface continued to be permitted, for compatibility with existing source code. C89 is supported by current C compilers, and most modern C code is based on it. Any program written only in Standard C and without any hardware-dependent assumptions will run correctly on any [platform](https://en.wikipedia.org/wiki/Computing_platform "Computing platform") with a conforming C implementation, within its resource limits. Without such precautions, programs may compile only on a certain platform or with a particular compiler, due, for example, to the use of non-standard libraries, such as [GUI](https://en.wikipedia.org/wiki/GUI "GUI") libraries, or to a reliance on compiler- or platform-specific attributes such as the exact size of data types and byte [endianness](https://en.wikipedia.org/wiki/Endianness "Endianness"). In cases where code must be compilable by either standard-conforming or K\&R C-based compilers, the `__STDC__` macro can be used to split the code into Standard and K\&R sections to prevent the use on a K\&R C-based compiler of features available only in Standard C. After the ANSI/ISO standardization process, the C language specification remained relatively static for several years. In 1995, Normative Amendment 1 to the 1990 C standard (ISO/IEC 9899/AMD1:1995, known informally as C95) was published, to correct some details and to add more extensive support for international character sets.[\[28\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-NWUon-33) Main article: [C99](https://en.wikipedia.org/wiki/C99 "C99") The C standard was further revised in the late 1990s, leading to the publication of ISO/IEC 9899:1999 in 1999, which is commonly referred to as "[C99](https://en.wikipedia.org/wiki/C99 "C99")". It has since been amended three times by Technical Corrigenda.[\[29\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-WG14-34) C99 introduced several new features, including [inline functions](https://en.wikipedia.org/wiki/Inline_function "Inline function"), several new [data types](https://en.wikipedia.org/wiki/Data_type "Data type") (including `long long int` and a `complex` type to represent [complex numbers](https://en.wikipedia.org/wiki/Complex_number "Complex number")), [variable-length arrays](https://en.wikipedia.org/wiki/Variable-length_array "Variable-length array") and [flexible array members](https://en.wikipedia.org/wiki/Flexible_array_member "Flexible array member"), improved support for [IEEE 754](https://en.wikipedia.org/wiki/IEEE_754 "IEEE 754") floating point, support for [variadic macros](https://en.wikipedia.org/wiki/Variadic_macro "Variadic macro") (macros of variable [arity](https://en.wikipedia.org/wiki/Arity "Arity")), and support for one-line comments beginning with `//`, as in BCPL or C++. Many of these had already been implemented as extensions in several C compilers. C99 is for the most part backward compatible with C90, but is stricter in some ways; in particular, a declaration that lacks a type specifier no longer has `int` implicitly assumed. A standard macro `__STDC_VERSION__` is defined with value `199901L` to indicate that C99 support is available. [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection"), [Solaris Studio](https://en.wikipedia.org/wiki/Solaris_Studio "Solaris Studio"), and other C compilers now\[*[when?](https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Chronological_items "Wikipedia:Manual of Style/Dates and numbers")*\] support many or all of the new features of C99. The C compiler in [Microsoft Visual C++](https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B "Microsoft Visual C++"), however, implements the C89 standard and those parts of C99 that are required for compatibility with [C++11](https://en.wikipedia.org/wiki/C%2B%2B11 "C++11").[\[30\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-YTKIv-35)\[*[needs update](https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Chronological_items "Wikipedia:Manual of Style/Dates and numbers")*\] In addition, the C99 standard requires support for [identifiers](https://en.wikipedia.org/wiki/Identifier_\(computer_languages\) "Identifier (computer languages)") using [Unicode](https://en.wikipedia.org/wiki/Unicode "Unicode") in the form of escaped characters (e.g. `\u0040` or `\U0001f431`) and suggests support for raw Unicode names. Main article: [C11](https://en.wikipedia.org/wiki/C11_\(C_standard_revision\) "C11 (C standard revision)") Work began in 2007 on another revision of the C standard, informally called "C1X" until its official publication of ISO/IEC 9899:2011 on December 8, 2011. The C standards committee adopted guidelines to limit the adoption of new features that had not been tested by existing implementations. The C11 standard adds numerous new features to C and the library, including type generic macros, anonymous structures, improved Unicode support, atomic operations, multi-threading, and bounds-checked functions. It also makes some portions of the existing C99 library optional, and improves compatibility with C++. The standard macro `__STDC_VERSION__` is defined as `201112L` to indicate that C11 support is available. Main article: [C17](https://en.wikipedia.org/wiki/C17_\(C_standard_revision\) "C17 (C standard revision)") C17 is an informal name for ISO/IEC 9899:2018, a standard for the C programming language published in June 2018. It introduces no new language features, only technical corrections, and clarifications to defects in C11. The standard macro `__STDC_VERSION__` is defined as `201710L` to indicate that C17 support is available. Main article: [C23](https://en.wikipedia.org/wiki/C23_\(C_standard_revision\) "C23 (C standard revision)") C23 is an informal name for the current major C language standard revision. It was known as "C2X" through most of its development. It builds on past releases, introducing features like new keywords, additional meaning for `auto` to provide [type inference](https://en.wikipedia.org/wiki/Type_inference "Type inference") when declaring variables, new types including `nullptr_t` and `_BitInt(N)`, and expansions to the standard library.[\[31\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-36) C23 was published in October 2024 as ISO/IEC 9899:2024.[\[32\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-N3132-37) The standard macro `__STDC_VERSION__` is defined as `202311L` to indicate that C23 support is available. Main article: [C2Y](https://en.wikipedia.org/wiki/C2Y_\(C_standard_revision\) "C2Y (C standard revision)") C2Y is an informal name for the next major C language standard revision, after C23 (C2X), that is hoped to be released later in the 2020s, hence the '2' in "C2Y". An early working draft of C2Y was released in February 2024 as N3220 by the working group [ISO/IEC JTC1/SC22](https://en.wikipedia.org/wiki/ISO/IEC_JTC1/SC22 "ISO/IEC JTC1/SC22")/WG14.[\[33\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-N3220-38) Historically, embedded C programming requires non-standard extensions to the C language to support exotic features such as [fixed-point arithmetic](https://en.wikipedia.org/wiki/Fixed-point_arithmetic "Fixed-point arithmetic"), multiple distinct [memory banks](https://en.wikipedia.org/wiki/Memory_bank "Memory bank"), and basic I/O operations. In 2008, the C Standards Committee published a [technical report](https://en.wikipedia.org/wiki/Technical_report "Technical report") extending the C language[\[34\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-TR18037-39) to address these issues by providing a common standard for all implementations to adhere to. It includes a number of features not available in normal C, such as fixed-point arithmetic, named address spaces, and basic I/O hardware addressing. C has a [formal grammar](https://en.wikipedia.org/wiki/Formal_grammar "Formal grammar") specified by the C standard.[\[35\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-h&s5e-40) Line endings are generally not significant in C; however, line boundaries do have significance during the preprocessing phase. Comments may appear either between the delimiters `/*` and `*/`, or (since C99) following `//` until the end of the line. Comments delimited by `/*` and `*/` do not nest, and these sequences of characters are not interpreted as comment delimiters if they appear inside [string](https://en.wikipedia.org/wiki/String_literal "String literal") or character literals.[\[36\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988192-41) C source files contain declarations and function definitions. Function definitions, in turn, contain declarations and [statements](https://en.wikipedia.org/wiki/Statement_\(computer_science\) "Statement (computer science)"). Declarations either define new types using keywords such as `struct`, `union`, and `enum`, or assign types to and perhaps reserve storage for new variables, usually by writing the type followed by the variable name. Keywords such as `char` and `int` specify built-in types. Sections of code are enclosed in braces (`{` and `}`, sometimes called "curly brackets") to limit the scope of declarations and to act as a single statement for control structures. As an imperative language, C uses *statements* to specify actions. The most common statement is an *expression statement*, consisting of an expression to be evaluated, followed by a semicolon; as a [side effect](https://en.wikipedia.org/wiki/Side_effect_\(computer_science\) "Side effect (computer science)") of the evaluation, [functions may be called](https://en.wikipedia.org/wiki/Function_\(computer_programming\) "Function (computer programming)") and [variables assigned](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)") new values. To modify the normal sequential execution of statements, C provides several control-flow statements identified by reserved keywords. [Structured programming](https://en.wikipedia.org/wiki/Structured_programming "Structured programming") is supported by `if` ... \[`else`\] conditional execution and by `do` ... `while`, `while`, and `for` iterative execution (looping). The `for` statement has separate initialization, testing, and reinitialization expressions, any or all of which can be omitted. `break` and `continue` can be used within the loop. Break is used to leave the innermost enclosing loop statement and continue is used to skip to its reinitialisation. There is also a non-structured `goto` statement, which branches directly to the designated [label](https://en.wikipedia.org/wiki/Label_\(computer_science\) "Label (computer science)") within the function. `switch` selects a `case` to be executed based on the value of an integer expression. Different from many other languages, control-flow will [fall through](https://en.wikipedia.org/wiki/Switch_statement#Fallthrough "Switch statement") to the next `case` unless terminated by a `break`. Expressions can use a variety of built-in operators and may contain function calls. The order in which arguments to functions and operands to most operators are evaluated is unspecified. The evaluations may even be interleaved. However, all side effects (including storage to variables) will occur before the next "[sequence point](https://en.wikipedia.org/wiki/Sequence_point "Sequence point")"; sequence points include the end of each expression statement, and the entry to and return from each function call. Sequence points also occur during evaluation of expressions containing certain operators (`&&`, `||`, `?:` and the [comma operator](https://en.wikipedia.org/wiki/Comma_operator "Comma operator")). This permits a high degree of object code optimization by the compiler, but requires C programmers to take more care to obtain reliable results than is needed for other programming languages. Kernighan and Ritchie say in the Introduction of *The C Programming Language*: "C, like any other language, has its blemishes. Some of the operators have the wrong precedence; some parts of the syntax could be better."[\[37\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie19783-42) The C standard did not attempt to correct many of these blemishes, because of the impact of such changes on already existing software. The basic C source character set includes the following characters:[\[38\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-draft2007-43) - Lowercase and uppercase letters of the [ISO basic Latin alphabet](https://en.wikipedia.org/wiki/ISO_basic_Latin_alphabet "ISO basic Latin alphabet"): `a`–`z`, `A`–`Z` - Decimal digits: `0`–`9` - Graphic characters: `! " # % & ' ( ) * + , - . / : ; < = > ? [ \ ] ^ _ { | } ~` - [Whitespace characters](https://en.wikipedia.org/wiki/Whitespace_character "Whitespace character"): *[space](https://en.wikipedia.org/wiki/Space_\(punctuation\) "Space (punctuation)")*, *[horizontal tab](https://en.wikipedia.org/wiki/Horizontal_tab "Horizontal tab")*, *[vertical tab](https://en.wikipedia.org/wiki/Vertical_tab "Vertical tab")*, *[form feed](https://en.wikipedia.org/wiki/Form_feed "Form feed")*, *[newline](https://en.wikipedia.org/wiki/Newline "Newline")* The *newline* character indicates the end of a text line; it need not correspond to an actual single character, although for convenience C treats it as such. The POSIX standard mandates a [portable character set](https://en.wikipedia.org/wiki/Portable_character_set "Portable character set") which adds a few characters (notably "@") to the basic C source character set. Both standards do not prescribe any particular value encoding—[ASCII](https://en.wikipedia.org/wiki/ASCII "ASCII") and [EBCDIC](https://en.wikipedia.org/wiki/EBCDIC "EBCDIC") both comply with these standards, since they include at least those basic characters, even though they use different encoded values for those characters. Additional multi-byte encoded characters may be used in [string literals](https://en.wikipedia.org/wiki/String_literal "String literal"), but they are not entirely [portable](https://en.wikipedia.org/wiki/Software_portability "Software portability"). Since [C99](https://en.wikipedia.org/wiki/C99 "C99") multi-national Unicode characters can be embedded portably within C source text by using `\uXXXX` or `\UXXXXXXXX` encoding (where `X` denotes a hexadecimal character). The basic C execution character set contains the same characters, along with representations for the [null character](https://en.wikipedia.org/wiki/Null_character "Null character"), [alert](https://en.wikipedia.org/wiki/Bell_character "Bell character"), [backspace](https://en.wikipedia.org/wiki/Backspace "Backspace"), and [carriage return](https://en.wikipedia.org/wiki/Carriage_return "Carriage return").[\[38\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-draft2007-43) [Run-time](https://en.wikipedia.org/wiki/Run_time_\(program_lifecycle_phase\) "Run time (program lifecycle phase)") support for extended character sets has increased with each revision of the C standard. All versions of C have [reserved words](https://en.wikipedia.org/wiki/Reserved_words "Reserved words") that are [case sensitive](https://en.wikipedia.org/wiki/Case_sensitive "Case sensitive"). As reserved words, they cannot be used for variable names. C89 has 32 reserved words: - `auto` - `break` - `case` - `char` - `const` - `continue` - `default` - `do` - `double` - `else` - `enum` - `extern` - `float` - `for` - `goto` - `if` - `int` - `long` - `register` - `return` - `short` - `signed` - `sizeof` - `static` - `struct` - `switch` - `typedef` - `union` - `unsigned` - `void` - `volatile` - `while` C99 added five more reserved words: (‡ indicates an alternative spelling alias for a C23 keyword) - `inline` - `restrict` - `_Bool` ‡ - `_Complex` - `_Imaginary` C11 added seven more reserved words:[\[39\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-ISOIEC_9899-44) (‡ indicates an alternative spelling alias for a C23 keyword) - `_Alignas` ‡ - `_Alignof` ‡ - `_Atomic` - `_Generic` - `_Noreturn` - `_Static_assert` ‡ - `_Thread_local` ‡ C23 reserved fifteen more words: - `alignas` - `alignof` - `bool` - `constexpr` - `false` - `nullptr` - `static_assert` - `thread_local` - `true` - `typeof` - `typeof_unqual` - `_BitInt` - `_Decimal32` - `_Decimal64` - `_Decimal128` Most of the recently reserved words begin with an underscore followed by a capital letter, because identifiers of that form were previously reserved by the C standard for use only by implementations. Since existing program source code should not have been using these identifiers, it would not be affected when C implementations started supporting these extensions to the programming language. Some standard headers do define more convenient synonyms for underscored identifiers. Some of those words were added as keywords with their conventional spelling in C23 and the corresponding macros were removed. Prior to C89, `entry` was reserved as a keyword. In the second edition of their book *[The C Programming Language](https://en.wikipedia.org/wiki/The_C_Programming_Language "The C Programming Language")*, which describes what became known as C89, Kernighan and Ritchie wrote, "The ... \[keyword\] `entry`, formerly reserved but never used, is no longer reserved." and "The stillborn `entry` keyword is withdrawn."[\[40\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988192,_259-45) C supports a rich set of [operators](https://en.wikipedia.org/wiki/Operator_\(computer_programming\) "Operator (computer programming)"), which are symbols used within an [expression](https://en.wikipedia.org/wiki/Expression_\(computer_science\) "Expression (computer science)") to specify the manipulations to be performed while evaluating that expression. C has operators for: - [arithmetic](https://en.wikipedia.org/wiki/Arithmetic "Arithmetic"): [`+`](https://en.wikipedia.org/wiki/Addition "Addition"), [`-`](https://en.wikipedia.org/wiki/Subtraction "Subtraction"), [`*`](https://en.wikipedia.org/wiki/Multiplication "Multiplication"), [`/`](https://en.wikipedia.org/wiki/Division_\(mathematics\) "Division (mathematics)"), [`%`](https://en.wikipedia.org/wiki/Modulo_operation "Modulo operation") - [assignment](https://en.wikipedia.org/wiki/Assignment_\(computer_science\) "Assignment (computer science)"): `=` - [augmented assignment](https://en.wikipedia.org/wiki/Augmented_assignment "Augmented assignment"): `+=`, `-=`, `*=`, `/=`, `%=`, `&=`, `|=`, `^=`, `<<=`, `>>=` - [bitwise logic](https://en.wikipedia.org/wiki/Bitwise_logic "Bitwise logic"): `~`, `&`, `|`, `^` - [bitwise shifts](https://en.wikipedia.org/wiki/Bitwise_shift "Bitwise shift"): `<<`, `>>` - [Boolean logic](https://en.wikipedia.org/wiki/Boolean_logic "Boolean logic"): `!`, `&&`, `||` - [conditional evaluation](https://en.wikipedia.org/wiki/%3F: "?:"): [`? :`](https://en.wikipedia.org/wiki/%3F: "?:") - equality testing: [`==`](https://en.wikipedia.org/wiki/Equality_\(mathematics\) "Equality (mathematics)"), [`!=`](https://en.wikipedia.org/wiki/Inequality_\(mathematics\) "Inequality (mathematics)") - [calling functions](https://en.wikipedia.org/wiki/Subroutine "Subroutine"): `( )` - [increment and decrement](https://en.wikipedia.org/wiki/Increment_and_decrement_operators "Increment and decrement operators"): `++`, `--` - [member selection](https://en.wikipedia.org/wiki/Record_\(computer_science\) "Record (computer science)"): `.`, `->` - object size: `sizeof` - type: `typeof`, `typeof_unqual` *since C23* - [order relations](https://en.wikipedia.org/wiki/Order_relation "Order relation"): `<`, `<=`, `>`, `>=` - [reference and dereference](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)"): `&`, `*`, `[ ]` - sequencing: [`,`](https://en.wikipedia.org/wiki/Comma_operator "Comma operator") - [subexpression grouping](https://en.wikipedia.org/wiki/Order_of_operations#Programming_languages "Order of operations"): `( )` - [type conversion](https://en.wikipedia.org/wiki/Type_conversion "Type conversion"): `(typename)` C uses the operator `=` (used in mathematics to express equality) to indicate assignment, following the precedent of [Fortran](https://en.wikipedia.org/wiki/Fortran "Fortran") and [PL/I](https://en.wikipedia.org/wiki/PL/I "PL/I"), but unlike [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") and its derivatives. C uses the operator `==` to test for equality. The similarity between the operators for assignment and equality may result in the accidental use of one in place of the other, and in many cases the mistake does not produce an error message (although some compilers produce warnings). For example, the conditional expression `if (a == b + 1)` might mistakenly be written as `if (a = b + 1)`, which will be evaluated as `true` unless the value of `a` is `0` after the assignment.[\[41\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-AutoTX-8-46) The C [operator precedence](https://en.wikipedia.org/wiki/Operator_precedence "Operator precedence") is not always intuitive. For example, the operator `==` binds more tightly than (is executed prior to) the operators `&` (bitwise AND) and `|` (bitwise OR) in expressions such as `x & 1 == 0`, which must be written as `(x & 1) == 0` if that is the coder's intent.[\[42\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-AutoTX-9-47) [![](https://upload.wikimedia.org/wikipedia/commons/thumb/3/30/1999_ISO_C_Concepts.png/250px-1999_ISO_C_Concepts.png)](https://en.wikipedia.org/wiki/File:1999_ISO_C_Concepts.png) The [type system](https://en.wikipedia.org/wiki/Type_system "Type system") in C is [static](https://en.wikipedia.org/wiki/Static_typing "Static typing") and [weakly typed](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"), which makes it similar to the type system of [ALGOL](https://en.wikipedia.org/wiki/ALGOL "ALGOL") descendants such as [Pascal](https://en.wikipedia.org/wiki/Pascal_\(programming_language\) "Pascal (programming language)").[\[43\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Nmlwr-48) There are built-in types for integers of various sizes, both signed and unsigned, [floating-point numbers](https://en.wikipedia.org/wiki/Floating-point_number "Floating-point number"), and enumerated types (`enum`). Integer type `char` is often used for single-byte characters. C99 added a [Boolean data type](https://en.wikipedia.org/wiki/Boolean_data_type "Boolean data type"). There are also derived types including [arrays](https://en.wikipedia.org/wiki/Array_\(data_type\) "Array (data type)"), [pointers](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)"), [records](https://en.wikipedia.org/wiki/Record_\(computer_science\) "Record (computer science)") (`struct`), and [unions](https://en.wikipedia.org/wiki/Union_\(computer_science\) "Union (computer science)") (`union`). C is often used in low-level systems programming where escapes from the type system may be necessary. The compiler attempts to ensure type correctness of most expressions, but the programmer can override the checks in various ways, either by using a *[type cast](https://en.wikipedia.org/wiki/Type_conversion "Type conversion")* to explicitly convert a value from one type to another, or by using pointers or unions to reinterpret the underlying bits of a data object in some other way. Some find C's declaration syntax unintuitive, particularly for [function pointers](https://en.wikipedia.org/wiki/Function_pointer "Function pointer"). (Ritchie's idea was to declare identifiers in contexts resembling their use: "[declaration reflects use](https://en.wikipedia.org/wiki/Declaration_reflects_use "Declaration reflects use")".)[\[44\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTEKernighanRitchie1988122-49) C's *usual arithmetic conversions* allow for efficient code to be generated, but can sometimes produce unexpected results. For example, a comparison of signed and unsigned integers of equal width requires a conversion of the signed value to unsigned. This can generate unexpected results if the signed value is negative. C supports the use of [pointers](https://en.wikipedia.org/wiki/Pointer_\(computer_programming\) "Pointer (computer programming)"), a type of [reference](https://en.wikipedia.org/wiki/Reference_\(computer_science\) "Reference (computer science)") that records the address or location of an object or function in memory. Pointers can be *dereferenced* to access data stored at the address pointed to, or to invoke a pointed-to function. Pointers can be manipulated using assignment or [pointer arithmetic](https://en.wikipedia.org/wiki/Pointer_arithmetic "Pointer arithmetic"). The run-time representation of a pointer value is typically a raw memory address (perhaps augmented by an offset-within-word field), but since a pointer's type includes the type of the thing pointed to, expressions including pointers can be type-checked at compile time. Pointer arithmetic is automatically scaled by the size of the pointed-to data type. Pointers are used for many purposes in C. [Text strings](https://en.wikipedia.org/wiki/Text_string "Text string") are commonly manipulated using pointers into arrays of characters. [Dynamic memory allocation](https://en.wikipedia.org/wiki/Dynamic_memory_allocation "Dynamic memory allocation") is performed using pointers; the result of a `malloc` is usually [cast](https://en.wikipedia.org/wiki/Type_conversion "Type conversion") to the data type of the data to be stored. Many data types, such as [trees](https://en.wikipedia.org/wiki/Tree_\(data_structure\) "Tree (data structure)"), are commonly implemented as dynamically allocated `struct` objects linked together using pointers. Pointers to other pointers are often used in multi-dimensional arrays and arrays of `struct` objects. Pointers to functions (*[function pointers](https://en.wikipedia.org/wiki/Function_pointer "Function pointer")*) are useful for passing functions as arguments to [higher-order functions](https://en.wikipedia.org/wiki/Higher-order_function "Higher-order function") (such as [qsort](https://en.wikipedia.org/wiki/Qsort "Qsort") or [bsearch](https://en.wikipedia.org/wiki/Bsearch "Bsearch")), in [dispatch tables](https://en.wikipedia.org/wiki/Dispatch_table "Dispatch table"), or as [callbacks](https://en.wikipedia.org/wiki/Callbacks "Callbacks") to [event handlers](https://en.wikipedia.org/wiki/Event_handler "Event handler").[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) A *[null pointer](https://en.wikipedia.org/wiki/Null_pointer "Null pointer") value* explicitly points to no valid location. Dereferencing a null pointer value is undefined, often resulting in a [segmentation fault](https://en.wikipedia.org/wiki/Segmentation_fault "Segmentation fault"). Null pointer values are useful for indicating special cases such as no "next" pointer in the final node of a [linked list](https://en.wikipedia.org/wiki/Linked_list "Linked list"), or as an error indication from functions returning pointers. In appropriate contexts in source code, such as for assigning to a pointer variable, a *null pointer constant* can be written as `0`, with or without explicit casting to a pointer type, as the `NULL` macro defined by several standard headers or, since C23 with the constant `nullptr`. In conditional contexts, null pointer values evaluate to `false`, while all other pointer values evaluate to `true`. Void pointers (`void *`) point to objects of unspecified type, and can therefore be used as "generic" data pointers. Since the size and type of the pointed-to object is not known, void pointers cannot be dereferenced, nor is pointer arithmetic on them allowed, although they can easily be (and in many contexts implicitly are) converted to and from any other object pointer type.[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) Careless use of pointers is potentially dangerous. Because they are typically unchecked, a pointer variable can be made to point to any arbitrary location, which can cause undesirable effects. Although properly used pointers point to safe places, they can be made to point to unsafe places by using invalid [pointer arithmetic](https://en.wikipedia.org/wiki/Pointer_arithmetic "Pointer arithmetic"); the objects they point to may continue to be used after deallocation ([dangling pointers](https://en.wikipedia.org/wiki/Dangling_pointer "Dangling pointer")); they may be used without having been initialized ([wild pointers](https://en.wikipedia.org/wiki/Wild_pointer "Wild pointer")); or they may be directly assigned an unsafe value using a cast, union, or through another corrupt pointer. In general, C is permissive in allowing manipulation of and conversion between pointer types, although compilers typically provide options for various levels of checking. Some other programming languages address these problems by using more restrictive [reference](https://en.wikipedia.org/wiki/Reference_\(computer_science\) "Reference (computer science)") types. [Array](https://en.wikipedia.org/wiki/Array_\(data_type\) "Array (data type)") types in C are traditionally of a fixed, static size specified at compile time. The more recent C99 standard also allows a form of variable-length arrays. However, it is also possible to allocate a block of memory (of arbitrary size) at run time, using the standard library's `malloc` function, and treat it as an array. Since arrays are always accessed (in effect) via pointers, array accesses are typically not checked against the underlying array size, although some compilers may provide [bounds checking](https://en.wikipedia.org/wiki/Bounds_checking "Bounds checking") as an option.[\[45\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-fedoraproject-50)[\[46\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Programming_with_C-51) Array bounds violations are therefore possible and can lead to various repercussions, including illegal memory accesses, corruption of data, [buffer overruns](https://en.wikipedia.org/wiki/Buffer_overruns "Buffer overruns"), and run-time exceptions. C does not have a special provision for declaring [multi-dimensional arrays](https://en.wikipedia.org/wiki/Multi-dimensional_array "Multi-dimensional array"), but rather relies on [recursion](https://en.wikipedia.org/wiki/Recursion_\(computer_science\) "Recursion (computer science)") within the type system to declare arrays of arrays, which effectively accomplishes the same thing. The index values of the resulting "multi-dimensional array" can be thought of as increasing in [row-major order](https://en.wikipedia.org/wiki/Row-major_order "Row-major order"). Multi-dimensional arrays are commonly used in numerical algorithms (mainly from applied [linear algebra](https://en.wikipedia.org/wiki/Linear_algebra "Linear algebra")) to store matrices. The structure of the C array is well suited to this particular task. However, in early versions of C the bounds of the array must be known fixed values or else explicitly passed to any subroutine that requires them, and dynamically sized arrays of arrays cannot be accessed using double indexing. (A workaround for this was to allocate the array with an additional "row vector" of pointers to the columns.) C99 introduced "variable-length arrays" which address this issue. The following example using modern C (C99 or later) shows allocation of a two-dimensional array on the heap and the use of multi-dimensional array indexing for accesses (which can use bounds-checking on many C compilers): ``` int func(int n, int m) { float (*p)[n][m] = malloc(sizeof *p); if (p == NULL) { return -1; } for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { (*p)[i][j] = i + j; } } print_array(n, m, p); free(p); return 1; } ``` And here is a similar implementation using C99's *Auto [VLA](https://en.wikipedia.org/wiki/Variable_length_array "Variable length array")* feature:[\[f\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-52) ``` int func(int n, int m) { // Caution: checks should be made to ensure n * m * sizeof(float) does NOT exceed limitations for auto VLAs and is within available size of stack. float p[n][m]; // auto VLA is held on the stack, and sized when the function is invoked for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { p[i][j] = i + j; } } print_array(n, m, p); // no need to free(p) since it will disappear when the function exits, along with the rest of the stack frame return 1; } ``` #### Array–pointer interchangeability \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=23 "Edit section: Array–pointer interchangeability")\] The subscript notation `x[i]` (where `x` designates a pointer) is [syntactic sugar](https://en.wikipedia.org/wiki/Syntactic_sugar "Syntactic sugar") for `*(x+i)`.[\[47\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Raymond1996-53) Taking advantage of the compiler's knowledge of the pointer type, the address that `x + i` points to is not the base address (pointed to by `x`) incremented by `i` bytes, but rather is defined to be the base address incremented by `i` multiplied by the size of an element that `x` points to. Thus, `x[i]` designates the `i+1`th element of the array. Furthermore, in most expression contexts (a notable exception is as operand of `sizeof`), an expression of array type is automatically converted to a pointer to the array's first element. This implies that an array is never copied as a whole when named as an argument to a function, but rather only the address of its first element is passed. Therefore, although function calls in C use [pass-by-value](https://en.wikipedia.org/wiki/Pass-by-value "Pass-by-value") semantics, arrays are in effect passed by [reference](https://en.wikipedia.org/wiki/Reference_\(computer_science\) "Reference (computer science)"). The total size of an array `x` can be determined by applying `sizeof` to an expression of array type. The size of an element can be determined by applying the operator `sizeof` to any dereferenced element of an array `A`, as in `n = sizeof A[0]`. Thus, the number of elements in a declared array `A` can be determined as `sizeof A / sizeof A[0]`. Note, that if only a pointer to the first element is available as it is often the case in C code because of the automatic conversion described above, the information about the full type of the array and its length are lost. One of the most important functions of a programming language is to provide facilities for managing [memory](https://en.wikipedia.org/wiki/Computer_memory "Computer memory") and the objects that are stored in memory. C provides three principal ways to allocate memory for objects:[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) - [Static memory allocation](https://en.wikipedia.org/wiki/Static_memory_allocation "Static memory allocation"): space for the object is provided in the binary at compile time; these objects have an [extent](https://en.wikipedia.org/wiki/Variable_\(programming\)#Scope_and_extent "Variable (programming)") (or lifetime) as long as the binary which contains them is loaded into memory. - [Automatic memory allocation](https://en.wikipedia.org/wiki/Automatic_memory_allocation "Automatic memory allocation"): temporary objects can be stored on the [stack](https://en.wikipedia.org/wiki/Call_stack "Call stack"), and this space is automatically freed and reusable after the block in which they are declared is exited. - [Dynamic memory allocation](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation"): blocks of memory of arbitrary size can be requested at run time using library functions such as `malloc` from a region of memory called the [heap](https://en.wikipedia.org/wiki/Memory_management "Memory management"); these blocks persist until subsequently freed for reuse by calling the library function `realloc` or `free`. These three approaches are appropriate in different situations and have various trade-offs. For example, static memory allocation has little allocation overhead, automatic allocation may involve slightly more overhead, and dynamic memory allocation can potentially have a great deal of overhead for both allocation and deallocation. The persistent nature of static objects is useful for maintaining state information across function calls, automatic allocation is easy to use but stack space is typically much more limited and transient than either static memory or heap space, and dynamic memory allocation allows convenient allocation of objects whose size is known only at run time. Most C programs make extensive use of all three. Where possible, automatic or static allocation is usually simplest because the storage is managed by the compiler, freeing the programmer of the potentially error-prone chore of manually allocating and releasing storage. However, many data structures can change in size at run time, and since static allocations (and automatic allocations before C99) must have a fixed size at compile time, there are many situations in which dynamic allocation is necessary.[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) Prior to the C99 standard, variable-sized arrays were a common example of this. (See the article on [C dynamic memory allocation](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation") for an example of dynamically allocated arrays.) Unlike automatic allocation, which can fail at run time with uncontrolled consequences, the dynamic allocation functions return an indication (in the form of a null pointer value) when the required storage cannot be allocated. (Static allocation that is too large is usually detected by the [linker](https://en.wikipedia.org/wiki/Linker_\(computing\) "Linker (computing)") or [loader](https://en.wikipedia.org/wiki/Loader_\(computing\) "Loader (computing)"), before the program can even begin execution.) Unless otherwise specified, static objects contain zero or null pointer values upon program startup. Automatically and dynamically allocated objects are initialized only if an initial value is explicitly specified; otherwise they initially have indeterminate values (typically, whatever [bit pattern](https://en.wikipedia.org/wiki/Bit_pattern "Bit pattern") happens to be present in the [storage](https://en.wikipedia.org/wiki/Computer_storage "Computer storage"), which might not even represent a valid value for that type). If the program attempts to access an uninitialized value, the results are undefined. Many modern compilers try to detect and warn about this problem, but both [false positives and false negatives](https://en.wikipedia.org/wiki/Type_I_and_type_II_errors "Type I and type II errors") can occur. Heap memory allocation has to be synchronized with its actual usage in any program to be reused as much as possible. For example, if the only pointer to a heap memory allocation goes out of scope or has its value overwritten before it is deallocated explicitly, then that memory cannot be recovered for later reuse and is essentially lost to the program, a phenomenon known as a *[memory leak](https://en.wikipedia.org/wiki/Memory_leak "Memory leak")*. Conversely, it is possible for memory to be freed but referenced subsequently, leading to unpredictable results. Typically, the failure symptoms appear in a portion of the program unrelated to the code that causes the error, making it difficult to diagnose the failure. Such issues are ameliorated in languages with [automatic garbage collection](https://en.wikipedia.org/wiki/Automatic_garbage_collection "Automatic garbage collection"). The C programming language uses [libraries](https://en.wikipedia.org/wiki/Library_\(computing\) "Library (computing)") as its primary method of extension. In C, a library is a set of functions contained within a single "archive" file. Each library typically has a [header file](https://en.wikipedia.org/wiki/Header_file "Header file"), which contains the prototypes of the functions contained within the library that may be used by a program, and declarations of special data types and macro symbols used with these functions. For a program to use a library, it must include the library's header file, and the library must be linked with the program, which in many cases requires [compiler flags](https://en.wikipedia.org/wiki/Compiler_flag "Compiler flag") (e.g., `-lm`, shorthand for "link the math library").[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) The most common C library is the [C standard library](https://en.wikipedia.org/wiki/C_standard_library "C standard library"), which is specified by the [ISO](https://en.wikipedia.org/wiki/ISO_standard "ISO standard") and [ANSI C](https://en.wikipedia.org/wiki/ANSI_C "ANSI C") standards and comes with every C implementation (implementations which target limited environments such as [embedded systems](https://en.wikipedia.org/wiki/Embedded_system "Embedded system") may provide only a subset of the standard library). This library supports stream input and output, memory allocation, mathematics, character strings, and time values. Several separate standard headers (for example, `stdio.h`) specify the interfaces for these and other standard library facilities. Another common set of C library functions are those used by applications specifically targeted for [Unix](https://en.wikipedia.org/wiki/Unix "Unix") and [Unix-like](https://en.wikipedia.org/wiki/Unix-like "Unix-like") systems, especially functions which provide an interface to the [kernel](https://en.wikipedia.org/wiki/Kernel_\(operating_system\) "Kernel (operating system)"). These functions are detailed in various standards such as [POSIX](https://en.wikipedia.org/wiki/POSIX "POSIX") and the [Single UNIX Specification](https://en.wikipedia.org/wiki/Single_UNIX_Specification "Single UNIX Specification"). Since many programs have been written in C, there are a wide variety of other libraries available. Libraries are often written in C because C compilers generate efficient [object code](https://en.wikipedia.org/wiki/Object_code "Object code"); programmers then create interfaces to the library so that the routines can be used from higher-level languages like [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)"), [Perl](https://en.wikipedia.org/wiki/Perl "Perl"), and [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)").[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) #### File handling and streams \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=26 "Edit section: File handling and streams")\] File input and output (I/O) is not part of the C language itself but instead is handled by libraries (such as the C standard library) and their associated header files (e.g. `stdio.h`). File handling is generally implemented through high-level I/O which works through [streams](https://en.wikipedia.org/wiki/Stream_\(computing\) "Stream (computing)"). A stream is from this perspective a data flow that is independent of devices, while a file is a concrete device. The high-level I/O is done through the association of a stream to a file. In the C standard library, a [buffer](https://en.wikipedia.org/wiki/Data_buffer "Data buffer") (a memory area or queue) is temporarily used to store data before it is sent to the final destination. This reduces the time spent waiting for slower devices, for example a [hard drive](https://en.wikipedia.org/wiki/Hard_drive "Hard drive") or [solid-state drive](https://en.wikipedia.org/wiki/Solid-state_drive "Solid-state drive"). Low-level I/O functions are not part of the standard C library\[*[clarification needed](https://en.wikipedia.org/wiki/Wikipedia:Please_clarify "Wikipedia:Please clarify")*\] but are generally part of "bare metal" programming (programming that is independent of any [operating system](https://en.wikipedia.org/wiki/Operating_system "Operating system") such as most [embedded programming](https://en.wikipedia.org/wiki/Embedded_programming "Embedded programming")). With few exceptions, implementations include low-level I/O. A number of tools have been developed to help C programmers find and fix statements with undefined behavior or possibly erroneous expressions, with greater rigor than that provided by the compiler. Automated source code checking and auditing tools exist, such as [Lint](https://en.wikipedia.org/wiki/Lint_\(software\) "Lint (software)"). A common practice is to use Lint to detect questionable code when a program is first written. Once a program passes Lint, it is then compiled using the C compiler. Also, many compilers can optionally warn about syntactically valid constructs that are likely to actually be errors. [MISRA C](https://en.wikipedia.org/wiki/MISRA_C "MISRA C") is a proprietary set of guidelines to avoid such questionable code, developed for embedded systems.[\[48\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-MI2L0-54) There are also compilers, libraries, and operating system level mechanisms for performing actions that are not a standard part of C, such as [bounds checking](https://en.wikipedia.org/wiki/Bounds_checking "Bounds checking") for arrays, detection of [buffer overflow](https://en.wikipedia.org/wiki/Buffer_overflow "Buffer overflow"), [serialization](https://en.wikipedia.org/wiki/Serialization "Serialization"), [dynamic memory](https://en.wikipedia.org/wiki/Dynamic_memory "Dynamic memory") tracking, and [automatic garbage collection](https://en.wikipedia.org/wiki/Automatic_garbage_collection "Automatic garbage collection"). Memory management checking tools like [Purify](https://en.wikipedia.org/wiki/IBM_Rational_Purify "IBM Rational Purify") or [Valgrind](https://en.wikipedia.org/wiki/Valgrind "Valgrind") and linking with libraries containing special versions of the [memory allocation functions](https://en.wikipedia.org/wiki/Malloc "Malloc") can help uncover run-time errors in memory usage.[\[49\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-55)[\[50\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-56) C has been widely used to implement [end-user](https://en.wikipedia.org/wiki/End-user_\(computer_science\) "End-user (computer science)") and system-level applications.[\[51\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-57) ### Rationale for use in systems programming \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=29 "Edit section: Rationale for use in systems programming")\] [![](https://upload.wikimedia.org/wikipedia/commons/thumb/1/10/The_C_Programming_Language.png/250px-The_C_Programming_Language.png)](https://en.wikipedia.org/wiki/File:The_C_Programming_Language.png) Some software written in C C is widely used for [systems programming](https://en.wikipedia.org/wiki/Systems_programming "Systems programming") in implementing [operating systems](https://en.wikipedia.org/wiki/Operating_system "Operating system") and [embedded system](https://en.wikipedia.org/wiki/Embedded_system "Embedded system") applications.[\[52\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Zh3CW-58) This is for several reasons: - The C language permits platform hardware and memory to be accessed with pointers and [type punning](https://en.wikipedia.org/wiki/Type_punning "Type punning"), so system-specific features (e.g. [Control/Status Registers](https://en.wikipedia.org/wiki/Control/Status_Register "Control/Status Register"), [I/O registers](https://en.wikipedia.org/wiki/Memory-mapped_I/O "Memory-mapped I/O")) can be configured and used with code written in C – it allows fullest control of the platform it is running on. - The code generated by compilation does not demand many [system features](https://en.wikipedia.org/wiki/Runtime_system "Runtime system"), and can be invoked from some boot code in a straightforward manner – it is simple to execute. - The C language statements and expressions typically map well to sequences of instructions for the target processor, and consequently there is a low [run-time](https://en.wikipedia.org/wiki/Run_time_\(program_lifecycle_phase\) "Run time (program lifecycle phase)") demand on system resources – it is fast to execute. - With its rich set of operators, the C language can use many of the features of target CPUs. Where a particular CPU has more esoteric instructions, a language variant can be constructed with perhaps [intrinsic functions](https://en.wikipedia.org/wiki/Intrinsic_function "Intrinsic function") to exploit those instructions – it can use practically all the target CPU's features. - The language makes it easy to overlay structures onto blocks of binary data, allowing the data to be comprehended, navigated and modified – it can write data structures, even file systems. - The language supports a rich set of operators, including bit manipulation, for integer arithmetic and logic, and perhaps different sizes of floating point numbers – it can process appropriately structured data effectively. - C is a fairly small language, with only a handful of statements, and without too many features that generate extensive target code – it is comprehensible. - C has direct control over memory allocation and deallocation, which gives reasonable efficiency and predictable timing to memory-handling operations, without any concerns for sporadic *[stop-the-world](https://en.wikipedia.org/wiki/Stop-the-world "Stop-the-world")* garbage collection events – it has predictable performance. - C permits the use and implementation of different [memory allocation](https://en.wikipedia.org/wiki/C_dynamic_memory_allocation "C dynamic memory allocation") schemes, including a typical `malloc` and `free`; a more sophisticated mechanism with [*arenas*](https://en.wikipedia.org/wiki/Region-based_memory_management "Region-based memory management"); or a version for an [OS kernel](https://en.wikipedia.org/wiki/OS_kernel "OS kernel") that may suit [DMA](https://en.wikipedia.org/wiki/Direct_memory_access "Direct memory access"), use within [interrupt handlers](https://en.wikipedia.org/wiki/Interrupt_handler "Interrupt handler"), or integrated with the [virtual memory](https://en.wikipedia.org/wiki/Virtual_memory "Virtual memory") system. - Depending on the linker and environment, C code can also call libraries written in [assembly language](https://en.wikipedia.org/wiki/Assembly_language "Assembly language"), and may be called from assembly language – it interoperates well with other lower-level code. - C and its [calling conventions](https://en.wikipedia.org/wiki/Calling_convention "Calling convention") and linker structures are commonly used in conjunction with other high-level languages, with calls both to C and from C supported – it interoperates well with other high-level code. - C has a mature and broad ecosystem, including libraries, frameworks, open source compilers, debuggers and utilities, and is the de facto standard. It is likely the drivers already exist in C, or that there is a similar CPU architecture as a back-end of a C compiler, so there is reduced incentive to choose another language. Computer games are often built from a combination of languages. C has featured significantly, especially for those games attempting to obtain best performance from computer platforms. Examples include [Doom](https://en.wikipedia.org/wiki/Doom_\(1993_video_game\) "Doom (1993 video game)") from 1993.[\[53\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-59) Historically, C was sometimes used for [web development](https://en.wikipedia.org/wiki/Web_development "Web development") using the [Common Gateway Interface](https://en.wikipedia.org/wiki/Common_Gateway_Interface "Common Gateway Interface") (CGI) as a "gateway" for information between the web application, the server, and the browser.[\[54\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-Dobbs_1995-60) C may have been chosen over [interpreted languages](https://en.wikipedia.org/wiki/Interpreted_language "Interpreted language") because of its speed, stability, and near-universal availability.[\[55\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-linuxjournal_2005-61) It is no longer common practice for web development to be done in C,[\[56\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-62) and many other [web development languages](https://en.wikipedia.org/wiki/Web_development#Server-side_languages "Web development") are popular. Applications where C-based web development continues include the [HTTP](https://en.wikipedia.org/wiki/HTTP "HTTP") configuration pages on [routers](https://en.wikipedia.org/wiki/Router_\(computing\) "Router (computing)"), [IoT](https://en.wikipedia.org/wiki/IoT "IoT") devices and similar, although even here some projects have parts in higher-level languages e.g. the use of [Lua](https://en.wikipedia.org/wiki/Lua "Lua") within [OpenWRT](https://en.wikipedia.org/wiki/OpenWRT "OpenWRT"). Two popular [web servers](https://en.wikipedia.org/wiki/Web_server "Web server"), [Apache HTTP Server](https://en.wikipedia.org/wiki/Apache_HTTP_Server "Apache HTTP Server") and [Nginx](https://en.wikipedia.org/wiki/Nginx "Nginx"), are written in C.[\[57\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-63)[\[58\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-64)\[*[better source needed](https://en.wikipedia.org/wiki/Wikipedia:Verifiability#Questionable_sources "Wikipedia:Verifiability")*\] C's close-to-the-metal approach allows for the construction of these high-performance software systems.\[*[citation needed](https://en.wikipedia.org/wiki/Wikipedia:Citation_needed "Wikipedia:Citation needed")*\] ### C as an intermediate language \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=32 "Edit section: C as an intermediate language")\] C is sometimes used as an [intermediate language](https://en.wikipedia.org/wiki/Intermediate_language "Intermediate language") by implementations of other languages. This approach may be used for portability or convenience; by using C as an intermediate language, additional machine-specific code generators are not necessary. C has some features, such as line-number preprocessor directives and optional superfluous commas at the end of initializer lists, that support compilation of generated code. However, some of C's shortcomings have prompted the development of other [C-based languages](https://en.wikipedia.org/wiki/List_of_C-family_programming_languages "List of C-family programming languages") specifically designed for use as intermediate languages, such as [C--](https://en.wikipedia.org/wiki/C-- "C--"). Also, contemporary major compilers [GCC](https://en.wikipedia.org/wiki/GNU_Compiler_Collection "GNU Compiler Collection") and [LLVM](https://en.wikipedia.org/wiki/LLVM "LLVM") both feature an [intermediate representation](https://en.wikipedia.org/wiki/Intermediate_representation "Intermediate representation") that is not C, and those compilers support front ends for many languages including C. ### Computationally intensive libraries \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=33 "Edit section: Computationally intensive libraries")\] C enables programmers to create efficient implementations of algorithms and data structures, because the layer of abstraction from hardware is thin, and its overhead is low, an important criterion for computationally intensive programs. For example, the [GNU Multiple Precision Arithmetic Library](https://en.wikipedia.org/wiki/GNU_Multiple_Precision_Arithmetic_Library "GNU Multiple Precision Arithmetic Library"), the [GNU Scientific Library](https://en.wikipedia.org/wiki/GNU_Scientific_Library "GNU Scientific Library"), [Mathematica](https://en.wikipedia.org/wiki/Mathematica "Mathematica"), and [MATLAB](https://en.wikipedia.org/wiki/MATLAB "MATLAB") are completely or partially written in C. Many languages support calling library functions in C; for example, the [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)")\-based framework [NumPy](https://en.wikipedia.org/wiki/NumPy "NumPy") uses C for the high-performance and hardware-interacting aspects. ### Other languages are written in C \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=34 "Edit section: Other languages are written in C")\] A consequence of C's wide availability and efficiency is that [compilers](https://en.wikipedia.org/wiki/Compiler "Compiler"), libraries and [interpreters](https://en.wikipedia.org/wiki/Interpreter_\(computing\) "Interpreter (computing)") of other programming languages are often implemented in C.[\[59\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-65) For example, the [reference implementations](https://en.wikipedia.org/wiki/Reference_implementation "Reference implementation") of [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)"),[\[60\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-66) [Perl](https://en.wikipedia.org/wiki/Perl "Perl"),[\[61\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-67) [Ruby](https://en.wikipedia.org/wiki/Ruby_\(programming_language\) "Ruby (programming language)"),[\[62\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-68) and [PHP](https://en.wikipedia.org/wiki/PHP "PHP")[\[63\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-69) are written in C. Ritchie himself joked about the limitations of the language that he created:[\[64\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-70) > the power of assembly language and the convenience of ... assembly language — Dennis Ritchie While C is popular, influential and hugely successful, it has drawbacks, including: - The standard [dynamic memory](https://en.wikipedia.org/wiki/Dynamic_memory "Dynamic memory") handling with `malloc` and `free` is prone to mistakes. Improper use can lead to [memory leaks](https://en.wikipedia.org/wiki/Memory_leaks "Memory leaks") and [dangling pointers](https://en.wikipedia.org/wiki/Dangling_pointers "Dangling pointers").[\[65\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-71) - The use of pointers and the direct manipulation of memory means corruption of memory is possible. - There is [type checking](https://en.wikipedia.org/wiki/Type_checking "Type checking"), yet it does not apply to some areas like [variadic functions](https://en.wikipedia.org/wiki/Variadic_functions "Variadic functions"), and the type checking can be trivially or inadvertently circumvented. It is [weakly typed](https://en.wikipedia.org/wiki/Strong_and_weak_typing "Strong and weak typing"), despite being statically typed. - Since the code generated by the compiler contains few run-time checks, there is a burden on the programmer to consider all possible outcomes, to protect against buffer overruns, array bounds checking, [stack overflows](https://en.wikipedia.org/wiki/Stack_overflow "Stack overflow"), memory exhaustion, and consider [race conditions](https://en.wikipedia.org/wiki/Race_condition#In_software "Race condition"), thread isolation, etc. - The use of pointers and the run-time manipulation of these enables two ways to access the same data (aliasing), which is not always determinable at compile time. This means that some optimizations that may be available to some other languages, such as Fortran, are not possible in C. For this reason, Fortran is sometimes considered faster.\[*[citation needed](https://en.wikipedia.org/wiki/Wikipedia:Citation_needed "Wikipedia:Citation needed")*\] - Some of the standard library functions, e.g. `scanf` or `strncat`, can lead to [buffer overruns](https://en.wikipedia.org/wiki/C_standard_library#Buffer_overflow_vulnerabilities "C standard library"). - There is limited standardization in support for low-level variants in generated code, such as different function [calling conventions](https://en.wikipedia.org/wiki/Calling_conventions "Calling conventions") and [ABIs](https://en.wikipedia.org/wiki/Application_binary_interface "Application binary interface"); different [structure packing](https://en.wikipedia.org/wiki/Data_structure_alignment "Data structure alignment") conventions; and different byte ordering within larger integers (including endianness). In many language implementations, some of these options may be handled with the preprocessor directive `#pragma`,[\[66\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-72)[\[67\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-73) and some with additional keywords e.g. use `__cdecl` calling convention. The directive and options are not consistently supported.[\[68\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-74) - [String handling](https://en.wikipedia.org/wiki/C_string_handling "C string handling") using the standard library is code-intensive, with explicit memory management required. - The language does not directly support object orientation, [introspection](https://en.wikipedia.org/wiki/Type_introspection "Type introspection"), run-time expression evaluation (like `eval` in JavaScript), garbage collection, etc. - There are few guards against misuse of language features, which may enable [unmaintainable](https://en.wikipedia.org/wiki/Software_maintenance "Software maintenance") code. In particular, the [C preprocessor](https://en.wikipedia.org/wiki/C_preprocessor "C preprocessor") can hide troubling effects such as double evaluation and worse.[\[69\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-75) This capability for obfuscated code has been celebrated with competitions such as the [International Obfuscated C Code Contest](https://en.wikipedia.org/wiki/International_Obfuscated_C_Code_Contest "International Obfuscated C Code Contest") and the [Underhanded C Contest](https://en.wikipedia.org/wiki/Underhanded_C_Contest "Underhanded C Contest"). - C lacks standard support for [exception handling](https://en.wikipedia.org/wiki/Exception_handling "Exception handling") and only offers [return codes](https://en.wikipedia.org/wiki/Return_code "Return code") for error checking. The [`setjmp` and `longjmp`](https://en.wikipedia.org/wiki/Setjmp.h "Setjmp.h") standard library functions have been used[\[70\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-76) to implement a try-catch mechanism via macros. Also, `goto` statements are commonly used for error handling.\[*[citation needed](https://en.wikipedia.org/wiki/Wikipedia:Citation_needed "Wikipedia:Citation needed")*\] ### Mitigations for C's problems \[[edit](https://en.wikipedia.org/w/index.php?title=C_\(programming_language\)&action=edit&section=36 "Edit section: Mitigations for C's problems")\] For some purposes, restricted styles of C have been adopted, e.g. [MISRA C](https://en.wikipedia.org/wiki/MISRA_C "MISRA C") or [CERT C](https://en.wikipedia.org/wiki/CERT_C "CERT C"), in an attempt to reduce the opportunity for unwanted behaviour.[\[71\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-77) Databases such as [CWE](https://en.wikipedia.org/wiki/Common_Weakness_Enumeration "Common Weakness Enumeration") attempt to count the ways that systems in general, especially those coded in C, have potential vulnerabilities, along with recommendations for mitigation. There are [tools](https://en.wikipedia.org/wiki/C_\(programming_language\)#Language_tools) that can mitigate some of the drawbacks. Contemporary C compilers include checks which may generate warnings to help identify many potential bugs. C's use of pointers can be made less risky by use of [instruction set architecture](https://en.wikipedia.org/wiki/Instruction_set_architecture "Instruction set architecture") extensions such as *[CHERI](https://en.wikipedia.org/wiki/CHERI "CHERI")* or *Permission Overlay Extensions*. These techniques change the fundamental nature of pointers at a hardware level to include bounds checks and purposes, which can help prevent buffer over-runs and inappropriate heap accesses. Since the early 2020s the Linux kernel has sections written in [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)"), a language which has specific measures to improve safety.[\[72\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-78) [![](https://upload.wikimedia.org/wikipedia/commons/thumb/f/ff/TIOBE_Index.webp/250px-TIOBE_Index.webp.png)](https://en.wikipedia.org/wiki/File:TIOBE_Index.webp) [TIOBE index](https://en.wikipedia.org/wiki/TIOBE_index "TIOBE index") Many languages developed after C were influenced by and borrowed aspects of C, including [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++"), [C\#](https://en.wikipedia.org/wiki/C_Sharp_\(programming_language\) "C Sharp (programming language)"), [C shell](https://en.wikipedia.org/wiki/C_shell "C shell"), [D](https://en.wikipedia.org/wiki/D_\(programming_language\) "D (programming language)"), [Go](https://en.wikipedia.org/wiki/Go_\(programming_language\) "Go (programming language)"), [Java](https://en.wikipedia.org/wiki/Java_\(programming_language\) "Java (programming language)"), [JavaScript](https://en.wikipedia.org/wiki/JavaScript "JavaScript"), [Julia](https://en.wikipedia.org/wiki/Julia_\(programming_language\) "Julia (programming language)"), [Limbo](https://en.wikipedia.org/wiki/Limbo_\(programming_language\) "Limbo (programming language)"), [LPC](https://en.wikipedia.org/wiki/LPC_\(programming_language\) "LPC (programming language)"), [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C"), [Perl](https://en.wikipedia.org/wiki/Perl "Perl"), [PHP](https://en.wikipedia.org/wiki/PHP "PHP"), [Python](https://en.wikipedia.org/wiki/Python_\(programming_language\) "Python (programming language)"), [Ruby](https://en.wikipedia.org/wiki/Ruby_\(programming_language\) "Ruby (programming language)"), [Rust](https://en.wikipedia.org/wiki/Rust_\(programming_language\) "Rust (programming language)"), [Swift](https://en.wikipedia.org/wiki/Swift_\(programming_language\) "Swift (programming language)"), [Verilog](https://en.wikipedia.org/wiki/Verilog "Verilog") and [SystemVerilog](https://en.wikipedia.org/wiki/SystemVerilog "SystemVerilog").[\[8\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-vinsp-10)[\[73\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-kafmy-79) Some claim that the most pervasive influence has been syntactical – that these languages combine the statement and expression syntax of C with type systems, data models and large-scale program structures that differ from those of C, sometimes radically. Several C or near-C interpreters exist, including [Ch](https://en.wikipedia.org/wiki/Ch_\(computer_programming\) "Ch (computer programming)") and [CINT](https://en.wikipedia.org/wiki/CINT "CINT"), which can also be used for scripting. When [object-oriented programming](https://en.wikipedia.org/wiki/Object-oriented_programming "Object-oriented programming") languages became popular, [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") and [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C") were two different extensions of C that provided object-oriented capabilities. Both languages were originally implemented as [source-to-source compilers](https://en.wikipedia.org/wiki/Source-to-source_compiler "Source-to-source compiler"); source code was translated into C, and then compiled with a C compiler.[\[74\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-dSI6f-80) The [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") programming language (originally named "C with [Classes](https://en.wikipedia.org/wiki/Class_\(programming\) "Class (programming)")") was devised by [Bjarne Stroustrup](https://en.wikipedia.org/wiki/Bjarne_Stroustrup "Bjarne Stroustrup") as an approach to providing [object-oriented](https://en.wikipedia.org/wiki/Object-oriented_programming "Object-oriented programming") functionality with a C-like syntax.[\[75\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-stroustrup_1993-81) C++ adds greater typing strength, scoping, and other tools useful in object-oriented programming, and permits [generic programming](https://en.wikipedia.org/wiki/Generic_programming "Generic programming") via templates. Nearly a superset of C, C++ now\[*[when?](https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Chronological_items "Wikipedia:Manual of Style/Dates and numbers")*\] supports most of C, with [a few exceptions](https://en.wikipedia.org/wiki/Compatibility_of_C_and_C%2B%2B "Compatibility of C and C++"). [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C") was originally a thin layer on top of C, and remains a strict [superset](https://en.wikipedia.org/wiki/Superset "Superset") of C that permits object-oriented programming using a hybrid dynamic/static typing paradigm. Objective-C derives its syntax from both C and [Smalltalk](https://en.wikipedia.org/wiki/Smalltalk "Smalltalk"): syntax that involves preprocessing, expressions, function declarations, and function calls is inherited from C, while the syntax for object-oriented features was originally taken from Smalltalk. In addition to [C++](https://en.wikipedia.org/wiki/C%2B%2B "C++") and [Objective-C](https://en.wikipedia.org/wiki/Objective-C "Objective-C"), [Ch](https://en.wikipedia.org/wiki/Ch_\(computer_programming\) "Ch (computer programming)"), [Cilk](https://en.wikipedia.org/wiki/Cilk "Cilk"), and [Unified Parallel C](https://en.wikipedia.org/wiki/Unified_Parallel_C "Unified Parallel C") are nearly supersets of C. - [Comparison of Pascal and C](https://en.wikipedia.org/wiki/Comparison_of_Pascal_and_C "Comparison of Pascal and C") - [Comparison of programming languages](https://en.wikipedia.org/wiki/Comparison_of_programming_languages "Comparison of programming languages") - [List of C compilers](https://en.wikipedia.org/wiki/List_of_C_compilers "List of C compilers") - [List of C programming books](https://en.wikipedia.org/wiki/List_of_computer_books#C "List of computer books") - [Outline of the C programming language](https://en.wikipedia.org/wiki/Outline_of_the_C_programming_language "Outline of the C programming language") 1. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-5)** "Thompson had made a brief attempt to produce a system coded in an early version of C—before structures—in 1972, but gave up the effort."[\[2\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a9-2)[\[3\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993b9-3)[\[4\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie2003-4) 2. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-9)** "The scheme of type composition adopted by C owes considerable debt to Algol 68, although it did not, perhaps, emerge in a form that Algol's adherents would approve of."[\[6\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993a8-7)[\[7\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie1993b8-8)[\[4\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-FOOTNOTERitchie2003-4) 3. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-12)** Pronounced , like the letter '[c](https://en.wikipedia.org/wiki/C "C")'.[\[9\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-11) 4. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-21)** The original example code will compile on most modern compilers that are not in strict standard compliance mode, but it does not fully conform to the requirements of either C89 or C99. In fact, C99 requires that a diagnostic message be produced. 5. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-23)** Return value `0` is typically used in this context to indicate success.[\[18\]](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_note-bk21st-22) 6. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-52)** Code of `print_array` (not shown) slightly differs also, because of the type of *p*, being a pointer to the 2D array in the malloc'd version, and just a 2D array in the auto VNA version. 1. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-C_in_a_Nutshell_1-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-C_in_a_Nutshell_1-1) Prinz, Peter; Crawford, Tony (December 16, 2005). [*C in a Nutshell*](https://books.google.com/books?id=4Mfe4sAMFUYC). O'Reilly Media, Inc. p. 3. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-596-55071-4](https://en.wikipedia.org/wiki/Special:BookSources/978-0-596-55071-4 "Special:BookSources/978-0-596-55071-4") . 2. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a9_2-0)** [Ritchie (1993a)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993a), p. 9. 3. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993b9_3-0)** [Ritchie (1993b)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993b), p. 9. 4. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie2003_4-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie2003_4-1) [Ritchie (2003)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie2003). 5. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-6)** ["N3221 – Editor's Report, Post January 2024 Strasbourg France Meeting"](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3221.htm). *ISO/IEC JTC1/SC22/WG14*. Open Standards. February 21, 2024. Retrieved May 24, 2024. 6. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a8_7-0)** [Ritchie (1993a)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993a), p. 8. 7. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993b8_8-0)** [Ritchie (1993b)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993b), p. 8. 8. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-vinsp_10-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-vinsp_10-1) ["Verilog HDL (and C)"](https://web.archive.org/web/20131106064022/http://cs.anu.edu.au/courses/ENGN3213/lectures/lecture6_VERILOG_2010.pdf) (PDF). The Research School of Computer Science at the Australian National University. June 3, 2010. Archived from [the original](http://cs.anu.edu.au/courses/ENGN3213/lectures/lecture6_VERILOG_2010.pdf) (PDF) on November 6, 2013. Retrieved August 19, 2013. "1980s: Verilog first introduced; Verilog inspired by the C programming language" 9. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-11)** ["The name is based on, and pronounced like the letter C in the English alphabet"](https://web.archive.org/web/20221117151137/https://eng.ichacha.net/pronounce/the%20c%20programming%20language.html). *the c programming language sound*. English Chinese Dictionary. Archived from [the original](https://eng.ichacha.net/pronounce/the%20c%20programming%20language.html) on November 17, 2022. Retrieved November 17, 2022. 10. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-13)** Munoz, Daniel. ["After All These Years, the World is Still Powered by C Programming \| Toptal"](https://www.toptal.com/c/after-all-these-years-the-world-is-still-powered-by-c-programming). *Toptal Engineering Blog*. Retrieved June 15, 2024. 11. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-14)** ["C Language Drops to Lowest Popularity Rating"](https://web.archive.org/web/20220822225609/https://www.developer.com/news/c-language-drops-to-lowest-popularity-rating/). *Developer.com*. August 9, 2016. Archived from [the original](https://www.developer.com/news/c-language-drops-to-lowest-popularity-rating/) on August 22, 2022. Retrieved August 1, 2022. 12. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-1) [***c***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-2) [***d***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-3) [***e***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-4) [***f***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-5) [***g***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTERitchie1993a_15-6) [Ritchie (1993a)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFRitchie1993a). 13. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-langpop_16-0)** ["Programming Language Popularity"](https://web.archive.org/web/20090116080326/http://www.langpop.com/). 2009. Archived from [the original](https://www.langpop.com/) on January 16, 2009. Retrieved January 16, 2009. 14. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-TIOBE-2009_17-0)** ["TIOBE Programming Community Index"](https://web.archive.org/web/20090504181627/http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html). 2009. Archived from [the original](https://www.tiobe.com/index.php/content/paperinfo/tpci/index.html) on May 4, 2009. Retrieved May 6, 2009. 15. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-ward198308_18-0)** Ward, Terry A. (August 1983). ["Annotated C / A Bibliography of the C Language"](https://archive.org/stream/byte-magazine-1983-08/1983_08_BYTE_08-08_The_C_Language#page/n267/mode/2up). *Byte*. p. 268. Retrieved January 31, 2015. 16. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-19)** ["TIOBE Index for September 2024"](https://web.archive.org/web/20240918165843/https://www.tiobe.com/tiobe-index/). Archived from [the original](https://www.tiobe.com/tiobe-index/) on September 18, 2024. Retrieved December 16, 2025. 17. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie19786_20-0)** [Kernighan & Ritchie (1978)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1978), p. 6. 18. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-1) [***c***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-2) [***d***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-3) [***e***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-4) [***f***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-5) [***g***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-bk21st_22-6) [Klemens, Ben](https://en.wikipedia.org/wiki/Ben_Klemens "Ben Klemens") (2013). *21st Century C*. [O'Reilly Media](https://en.wikipedia.org/wiki/O%27Reilly_Media "O'Reilly Media"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-4493-2714-9](https://en.wikipedia.org/wiki/Special:BookSources/978-1-4493-2714-9 "Special:BookSources/978-1-4493-2714-9") . 19. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-NFDsZ_24-0)** Ritchie, Dennis. ["BCPL to B to C"](https://web.archive.org/web/20191212221532/http://www.lysator.liu.se/c/dmr-on-histories.html). *lysator.liu.se*. Archived from [the original](https://www.lysator.liu.se/c/dmr-on-histories.html) on December 12, 2019. Retrieved September 10, 2019. 20. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-1) [***c***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-2) [***d***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-3) [***e***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Ars_25-4) Jensen, Richard (December 9, 2020). [""A damn stupid thing to do"—the origins of C"](https://web.archive.org/web/20220328143845/https://arstechnica.com/features/2020/12/a-damn-stupid-thing-to-do-the-origins-of-c/). *Ars Technica*. Archived from [the original](https://arstechnica.com/features/2020/12/a-damn-stupid-thing-to-do-the-origins-of-c/) on March 28, 2022. Retrieved March 28, 2022. 21. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-unixport_26-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-unixport_26-1) [Johnson, S. C.](https://en.wikipedia.org/wiki/Stephen_C._Johnson "Stephen C. Johnson"); [Ritchie, D. M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1978). "Portability of C Programs and the UNIX System". *Bell System Tech. J*. **57** (6): 2021–2048\. [CiteSeerX](https://en.wikipedia.org/wiki/CiteSeerX_\(identifier\) "CiteSeerX (identifier)") [10\.1.1.138.35](https://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.138.35). [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1002/j.1538-7305.1978.tb02141.x](https://doi.org/10.1002%2Fj.1538-7305.1978.tb02141.x). [ISSN](https://en.wikipedia.org/wiki/ISSN_\(identifier\) "ISSN (identifier)") [0005-8580](https://search.worldcat.org/issn/0005-8580). [S2CID](https://en.wikipedia.org/wiki/S2CID_\(identifier\) "S2CID (identifier)") [17510065](https://api.semanticscholar.org/CorpusID:17510065). (Note: The PDF is an OCR scan of the original, and contains a rendering of "IBM 370" as "IBM 310".) 22. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-QtqTh_27-0)** [McIlroy, M. D.](https://en.wikipedia.org/wiki/Doug_McIlroy "Doug McIlroy") (1987). [*A Research Unix reader: annotated excerpts from the Programmer's Manual, 1971–1986*](https://web.archive.org/web/20171111151817/http://www.cs.dartmouth.edu/~doug/reader.pdf) (PDF) (Technical report). CSTR. Bell Labs. p. 10. 139. Archived from [the original](http://www.cs.dartmouth.edu/~doug/reader.pdf) (PDF) on November 11, 2017. Retrieved February 1, 2015. 23. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1978_28-0)** [Kernighan & Ritchie (1978)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1978). 24. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-qOvzA_29-0)** "C manual pages". [*FreeBSD Miscellaneous Information Manual*](https://web.archive.org/web/20210121024455/https://nxmnpg.lemoda.net/7/c78) (FreeBSD 13.0 ed.). May 30, 2011. Archived from [the original](https://nxmnpg.lemoda.net/7/c78) on January 21, 2021. Retrieved January 15, 2021. [\[1\]](https://www.freebsd.org/cgi/man.cgi?query=c78&apropos=0&sektion=0&manpath=FreeBSD+9-current&arch=default&format=html) [Archived](https://web.archive.org/web/20210121033654/https://www.freebsd.org/cgi/man.cgi?query=c78&apropos=0&sektion=0&manpath=FreeBSD+9-current&arch=default&format=html) January 21, 2021, at the [Wayback Machine](https://en.wikipedia.org/wiki/Wayback_Machine "Wayback Machine") 25. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988_30-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988). 26. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-SkKfZ_31-0)** [Stroustrup, Bjarne](https://en.wikipedia.org/wiki/Bjarne_Stroustrup "Bjarne Stroustrup") (2002). [Sibling rivalry: C and C++](https://web.archive.org/web/20140824072719/http://www.stroustrup.com/sibling_rivalry.pdf) (PDF) (Report). AT\&T Labs. Archived from [the original](http://stroustrup.com/sibling_rivalry.pdf) (PDF) on August 24, 2014. Retrieved April 14, 2014. 27. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-32)** ["Rationale for American National Standard for Information Systems – Programming Language – C"](https://web.archive.org/web/20240717164722/https://www.cs.man.ac.uk/~pjj/cs211/c_rationale/node2.html). Archived from [the original](https://www.cs.man.ac.uk/~pjj/cs211/c_rationale/node2.html) on July 17, 2024. Retrieved July 17, 2024. 28. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-NWUon_33-0)** [*C Integrity*](https://web.archive.org/web/20180725033429/https://www.iso.org/standard/23909.html). International Organization for Standardization. March 30, 1995. Archived from [the original](https://www.iso.org/standard/23909.html) on July 25, 2018. Retrieved July 24, 2018. 29. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-WG14_34-0)** ["JTC1/SC22/WG14 – C"](https://web.archive.org/web/20180212100115/http://www.open-std.org/JTC1/SC22/WG14/). *Home page*. ISO/IEC. Archived from [the original](http://www.open-std.org/jtc1/sc22/wg14/) on February 12, 2018. Retrieved June 2, 2011. 30. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-YTKIv_35-0)** Andrew Binstock (October 12, 2011). ["Interview with Herb Sutter"](https://web.archive.org/web/20130802070446/http://www.drdobbs.com/cpp/interview-with-herb-sutter/231900562). *[Dr. Dobbs](https://en.wikipedia.org/wiki/Dr._Dobbs "Dr. Dobbs")*. Archived from [the original](http://www.drdobbs.com/cpp/interview-with-herb-sutter/231900562) on August 2, 2013. Retrieved September 7, 2013. 31. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-36)** ["ISO/IEC 9899:2024 (en) — N3220 working draft"](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3220.pdf) (PDF). Retrieved July 11, 2025. 32. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-N3132_37-0)** ["WG14-N3132 : Revised C23 Schedule"](https://web.archive.org/web/20230609204739/https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3132.pdf) (PDF). *open-std.org*. June 4, 2023. Archived from [the original](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3132.pdf) (PDF) on June 9, 2023. 33. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-N3220_38-0)** ["WG14-N3220 : Working Draft, C2y"](https://web.archive.org/web/20240226053735/https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3220.pdf) (PDF). *open-std.org*. February 21, 2024. Archived from [the original](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3220.pdf) (PDF) on February 26, 2024. 34. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-TR18037_39-0)** ["TR 18037: Embedded C"](https://web.archive.org/web/20210225224616/https://www.open-std.org/jtc1/sc22/wg14/www/docs/n1169.pdf) (PDF). *open-std.org*. April 4, 2006. ISO/IEC JTC1 SC22 WG14 N1169. Archived from [the original](https://www.open-std.org/jtc1/sc22/wg14/www/docs/n1169.pdf) (PDF) on February 25, 2021. Retrieved July 26, 2011. 35. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-h&s5e_40-0)** Harbison, Samuel P.; [Steele, Guy L.](https://en.wikipedia.org/wiki/Guy_L._Steele,_Jr. "Guy L. Steele, Jr.") (2002). *C: A Reference Manual* (5th ed.). [Englewood Cliffs, NJ](https://en.wikipedia.org/wiki/Englewood_Cliffs,_NJ "Englewood Cliffs, NJ"): [Prentice Hall](https://en.wikipedia.org/wiki/Prentice_Hall "Prentice Hall"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-089592-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-089592-9 "Special:BookSources/978-0-13-089592-9") . Contains a [BNF](https://en.wikipedia.org/wiki/Backus%E2%80%93Naur_form "Backus–Naur form") grammar for C. 36. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988192_41-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988), p. 192. 37. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie19783_42-0)** [Kernighan & Ritchie (1978)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1978), p. 3. 38. ^ [***a***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-draft2007_43-0) [***b***](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-draft2007_43-1) ["Committee Draft ISO/IEC 9899:TC3: 5.2.1 Character sets"](https://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf). 2007. 39. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-ISOIEC_9899_44-0)** ["ISO/IEC 9899:201x (ISO C11) Committee Draft"](https://web.archive.org/web/20171222215122/http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1548.pdf) (PDF). *open-std.org*. December 2, 2010. Archived from [the original](http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1548.pdf) (PDF) on December 22, 2017. Retrieved September 16, 2011. 40. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988192,_259_45-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988), pp. 192, 259. 41. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-AutoTX-8_46-0)** ["10 Common Programming Mistakes in C++"](https://web.archive.org/web/20081021080953/http://www.cs.ucr.edu/~nxiao/cs10/errors.htm). *Cs.ucr.edu*. Archived from [the original](http://www.cs.ucr.edu/~nxiao/cs10/errors.htm) on October 21, 2008. Retrieved June 26, 2009. 42. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-AutoTX-9_47-0)** Schultz, Thomas (2004). [*C and the 8051*](https://books.google.com/books?id=rI0c8kWbxooC&pg=PT47) (3rd ed.). Otsego, MI: PageFree Publishing Inc. p. 20. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-58961-237-2](https://en.wikipedia.org/wiki/Special:BookSources/978-1-58961-237-2 "Special:BookSources/978-1-58961-237-2") . Retrieved February 10, 2012. 43. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Nmlwr_48-0)** Feuer, Alan R.; Gehani, Narain H. (March 1982). "Comparison of the Programming Languages C and Pascal". *ACM Computing Surveys*. **14** (1): 73–92\. [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1145/356869.356872](https://doi.org/10.1145%2F356869.356872). [S2CID](https://en.wikipedia.org/wiki/S2CID_\(identifier\) "S2CID (identifier)") [3136859](https://api.semanticscholar.org/CorpusID:3136859). 44. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-FOOTNOTEKernighanRitchie1988122_49-0)** [Kernighan & Ritchie (1988)](https://en.wikipedia.org/wiki/C_\(programming_language\)#CITEREFKernighanRitchie1988), p. 122. 45. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-fedoraproject_50-0)** For example, gcc provides \_FORTIFY\_SOURCE. ["Security Features: Compile Time Buffer Checks (FORTIFY\_SOURCE)"](https://web.archive.org/web/20070107153447/http://fedoraproject.org/wiki/Security/Features). fedoraproject.org. Archived from [the original](https://fedoraproject.org/wiki/Security/Features) on January 7, 2007. Retrieved August 5, 2012. 46. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Programming_with_C_51-0)** เอี่ยมสิริวงศ์, โอภาศ (2016). *Programming with C*. Bangkok, Thailand: SE-EDUCATION PUBLIC COMPANY LIMITED. pp. 225–230\. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-616-08-2740-4](https://en.wikipedia.org/wiki/Special:BookSources/978-616-08-2740-4 "Special:BookSources/978-616-08-2740-4") . 47. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Raymond1996_53-0)** [Raymond, Eric S.](https://en.wikipedia.org/wiki/Eric_S._Raymond "Eric S. Raymond") (October 11, 1996). [*The New Hacker's Dictionary*](https://books.google.com/books?id=g80P_4v4QbIC&pg=PA432) (3rd ed.). MIT Press. p. 432. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-262-68092-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-262-68092-9 "Special:BookSources/978-0-262-68092-9") . Retrieved August 5, 2012. 48. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-MI2L0_54-0)** ["Man Page for lint (freebsd Section 1)"](http://www.unix.com/man-page/FreeBSD/1/lint). *unix.com*. May 24, 2001. Retrieved July 15, 2014. 49. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-55)** Hardison, Nate. ["CS107 Valgrind Memcheck"](https://web.stanford.edu/class/archive/cs/cs107/cs107.1236/resources/valgrind.html). *web.stanford.edu*. Retrieved June 23, 2023. 50. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-56)** Hastings, Reed; Joyce, Bob. ["Purify: Fast Detection of Memory Leaks and Access Errors"](https://web.stanford.edu/class/cs343/resources/purify.pdf) (PDF). *Pure Software Inc.*: 9. 51. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-57)** Munoz, Daniel. ["After All These Years, the World is Still Powered by C Programming"](https://www.toptal.com/c/after-all-these-years-the-world-is-still-powered-by-c-programming). *Toptal Engineering Blog*. Retrieved November 17, 2023. 52. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Zh3CW_58-0)** Dale, Nell B.; Weems, Chip (2014). *Programming and problem solving with C++* (6th ed.). Burlington, Massachusetts: Jones & Bartlett Learning. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-4496-9428-9](https://en.wikipedia.org/wiki/Special:BookSources/978-1-4496-9428-9 "Special:BookSources/978-1-4496-9428-9") . [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [894992484](https://search.worldcat.org/oclc/894992484). 53. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-59)** ["Development of Doom"](https://doomwiki.org/wiki/Development_of_Doom). *DoomWiki.org*. March 2, 2025. Retrieved March 2, 2025. 54. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-Dobbs_1995_60-0)** *Dr. Dobb's Sourcebook*. U.S.: Miller Freeman, Inc. November–December 1995. 55. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-linuxjournal_2005_61-0)** ["Using C for CGI Programming"](https://web.archive.org/web/20100213075858/http://www.linuxjournal.com/article/6863). linuxjournal.com. March 1, 2005. Archived from [the original](http://www.linuxjournal.com/article/6863) on February 13, 2010. Retrieved January 4, 2010. 56. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-62)** Perkins, Luc (September 17, 2013). ["Web development in C: crazy? Or crazy like a fox?"](https://web.archive.org/web/20141004135317/https://medium.com/@lucperkins/web-development-in-c-crazy-or-crazy-like-a-fox-ff723209f8f5). *Medium*. Archived from [the original](https://medium.com/@lucperkins/web-development-in-c-crazy-or-crazy-like-a-fox-ff723209f8f5) on October 4, 2014. Retrieved April 8, 2022. 57. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-63)** ["What programming language does NGINX use?"](https://mull-overthing.com/what-programming-language-does-nginx-use/). 58. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-64)** ["What is Apache and What Does it Do for Website Development?"](https://www.greengeeks.com/blog/what-is-apache/). February 15, 2022. 59. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-65)** ["C – the mother of all languages"](https://web.archive.org/web/20210531161841/https://ict.iitk.ac.in/c-the-mother-of-all-languages/). *ICT Academy at IITK*. November 13, 2018. Archived from [the original](https://ict.iitk.ac.in/c-the-mother-of-all-languages/) on May 31, 2021. Retrieved October 11, 2022. 60. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-66)** ["1. Extending Python with C or C++"](https://web.archive.org/web/20121105232707/https://docs.python.org/3/extending/extending.html). *Python 3.10.7 documentation*. Archived from [the original](https://docs.python.org/3/extending/extending.html) on November 5, 2012. Retrieved October 11, 2022. 61. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-67)** Conrad, Michael (January 22, 2018). ["An overview of the Perl 5 engine"](https://web.archive.org/web/20220526105419/https://opensource.com/article/18/1/perl-5-engine). *Opensource.com*. Archived from [the original](https://opensource.com/article/18/1/perl-5-engine) on May 26, 2022. Retrieved October 11, 2022. 62. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-68)** ["To Ruby From C and C++"](https://web.archive.org/web/20130812003928/https://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-c-and-cpp/). *Ruby Programming Language*. Archived from [the original](https://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-c-and-cpp/) on August 12, 2013. Retrieved October 11, 2022. 63. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-69)** Para, Michael (August 3, 2022). ["What is PHP? How to Write Your First PHP Program"](https://web.archive.org/web/20220804050401/https://www.freecodecamp.org/news/what-is-php-write-your-first-php-program/). *freeCodeCamp*. Archived from [the original](https://www.freecodecamp.org/news/what-is-php-write-your-first-php-program/) on August 4, 2022. Retrieved October 11, 2022. 64. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-70)** Metz, Cade (October 13, 2011). ["Dennis Ritchie: The Shoulders Steve Jobs Stood On"](https://web.archive.org/web/20220412005125/http://www.wired.com/2011/10/thedennisritchieeffect/). *Wired*. Archived from [the original](https://www.wired.com/2011/10/thedennisritchieeffect/) on April 12, 2022. Retrieved April 19, 2022. 65. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-71)** Internet Security Research Group. ["What is memory safety and why does it matter?"](https://www.memorysafety.org/docs/memory-safety/). *Prossimo*. Retrieved March 3, 2025. 66. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-72)** corob-msft (March 31, 2022). ["Pragma directives and the \_\_pragma and \_Pragma keywords"](https://web.archive.org/web/20220924075131/https://learn.microsoft.com/en-us/cpp/preprocessor/pragma-directives-and-the-pragma-keyword). *Microsoft Learn*. Archived from [the original](https://learn.microsoft.com/en-us/cpp/preprocessor/pragma-directives-and-the-pragma-keyword) on September 24, 2022. Retrieved September 24, 2022. 67. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-73)** ["Pragmas (The C Preprocessor)"](https://web.archive.org/web/20020617041757/https://gcc.gnu.org/onlinedocs/cpp/Pragmas.html). *GCC, the GNU Compiler Collection*. Archived from [the original](https://gcc.gnu.org/onlinedocs/cpp/Pragmas.html) on June 17, 2002. Retrieved September 24, 2022. 68. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-74)** ["Pragmas"](https://web.archive.org/web/20220410113529/https://www.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/pragmas.html). *Intel C++ Compiler Classic Developer Guide and Reference*. Intel. Archived from [the original](https://www.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/pragmas.html) on April 10, 2022. Retrieved April 10, 2022. 69. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-75)** ["In praise of the C preprocessor"](https://apenwarr.ca/log/20070813). *apenwarr*. August 13, 2007. Retrieved July 9, 2023. 70. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-76)** Roberts, Eric S. (March 21, 1989). ["Implementing Exceptions in C"](https://web.archive.org/web/20170115152453/http://bitsavers.informatik.uni-stuttgart.de/pdf/dec/tech_reports/SRC-RR-40.pdf) (PDF). [DEC Systems Research Center](https://en.wikipedia.org/wiki/DEC_Systems_Research_Center "DEC Systems Research Center"). SRC-RR-40. Archived from [the original](http://bitsavers.informatik.uni-stuttgart.de/pdf/dec/tech_reports/SRC-RR-40.pdf) (PDF) on January 15, 2017. Retrieved January 4, 2022. 71. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-77)** ["Secure Coding Overview"](https://apps.dtic.mil/sti/pdfs/AD1090471.pdf) (PDF). Software Engineering Institute, Carnegie Mellon University. Retrieved December 15, 2025. 72. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-78)** ["New Linux Patch Confirms: Rust Experiment Is Done, Rust Is Here To Stay"](https://www.phoronix.com/news/Rust-To-Stay-Linux-Kernel). *www.phoronix.com*. Retrieved December 15, 2025. 73. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-kafmy_79-0)** O'Regan, Gerard (September 24, 2015). *Pillars of computing : a compendium of select, pivotal technology firms*. Springer. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-3-319-21464-1](https://en.wikipedia.org/wiki/Special:BookSources/978-3-319-21464-1 "Special:BookSources/978-3-319-21464-1") . [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [922324121](https://search.worldcat.org/oclc/922324121). 74. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-dSI6f_80-0)** Rauchwerger, Lawrence (2004). *Languages and compilers for parallel computing : 16th international workshop, LCPC 2003, College Station, TX, USA, October 2–4, 2003 : revised papers*. Springer. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-3-540-24644-2](https://en.wikipedia.org/wiki/Special:BookSources/978-3-540-24644-2 "Special:BookSources/978-3-540-24644-2") . [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [57965544](https://search.worldcat.org/oclc/57965544). 75. **[^](https://en.wikipedia.org/wiki/C_\(programming_language\)#cite_ref-stroustrup_1993_81-0)** [Stroustrup, Bjarne](https://en.wikipedia.org/wiki/Bjarne_Stroustrup "Bjarne Stroustrup") (1993). ["A History of C++: 1979–1991"](https://web.archive.org/web/20190202050609/http://www.stroustrup.com/hopl2.pdf) (PDF). Archived from [the original](http://www.stroustrup.com/hopl2.pdf) (PDF) on February 2, 2019. Retrieved June 9, 2011. - [Kernighan, Brian W.](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan"); [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1978). [*The C Programming Language*](https://archive.org/details/cprogramminglang00kern/page/n2) (1st ed.). Englewood Cliffs: [Prentice Hall](https://en.wikipedia.org/wiki/Prentice_Hall "Prentice Hall"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-110163-0](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-110163-0 "Special:BookSources/978-0-13-110163-0") . [LCCN](https://en.wikipedia.org/wiki/LCCN_\(identifier\) "LCCN (identifier)") [77028983](https://lccn.loc.gov/77028983). [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [3608698](https://search.worldcat.org/oclc/3608698). [OL](https://en.wikipedia.org/wiki/OL_\(identifier\) "OL (identifier)") [4558528M](https://openlibrary.org/books/OL4558528M). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q63565563](https://www.wikidata.org/wiki/Q63565563 "d:Q63565563"). - [Kernighan, Brian W.](https://en.wikipedia.org/wiki/Brian_Kernighan "Brian Kernighan"); [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1988). [*The C Programming Language*](https://archive.org/details/cprogramminglang00bria/page/n4) (2nd ed.). Upper Saddle River: [Prentice Hall](https://en.wikipedia.org/wiki/Prentice_Hall "Prentice Hall"). [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-110362-7](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-110362-7 "Special:BookSources/978-0-13-110362-7") . [LCCN](https://en.wikipedia.org/wiki/LCCN_\(identifier\) "LCCN (identifier)") [88005934](https://lccn.loc.gov/88005934). [OCLC](https://en.wikipedia.org/wiki/OCLC_\(identifier\) "OCLC (identifier)") [254455874](https://search.worldcat.org/oclc/254455874). [OL](https://en.wikipedia.org/wiki/OL_\(identifier\) "OL (identifier)") [2030445M](https://openlibrary.org/books/OL2030445M). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q63413168](https://www.wikidata.org/wiki/Q63413168 "d:Q63413168"). - [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (March 1993a). [Wexelblat, Richard L.](https://en.wikipedia.org/wiki/Richard_Wexelblat "Richard Wexelblat") (ed.). ["The Development of the C Language"](https://dl.acm.org/doi/10.1145/155360.155580). *ACM SIGPLAN Notices*. **28** (3). New York City: [Association for Computing Machinery](https://en.wikipedia.org/wiki/Association_for_Computing_Machinery "Association for Computing Machinery"): 201–208\. [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1145/155360.155580](https://doi.org/10.1145%2F155360.155580). [ISSN](https://en.wikipedia.org/wiki/ISSN_\(identifier\) "ISSN (identifier)") [0362-1340](https://search.worldcat.org/issn/0362-1340). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q55869040](https://www.wikidata.org/wiki/Q55869040 "d:Q55869040"). - [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (1993b). Bergin, Thomas J.; Gibson, Richard G. (eds.). ["The Development of the C Language"](https://dl.acm.org/doi/10.1145/154766.155580). *The Second ACM SIGPLAN Conference on History of Programming Languages (HOPL-II)*. New York City: [Association for Computing Machinery](https://en.wikipedia.org/wiki/Association_for_Computing_Machinery "Association for Computing Machinery"): 201–208\. [doi](https://en.wikipedia.org/wiki/Doi_\(identifier\) "Doi (identifier)"):[10\.1145/154766.155580](https://doi.org/10.1145%2F154766.155580). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q29392176](https://www.wikidata.org/wiki/Q29392176 "d:Q29392176"). - [Ritchie, Dennis M.](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie") (2003) \[1993\]. [*The Development of the C Language*](https://web.archive.org/web/20250130134200/https://www.bell-labs.com/usr/dmr/www/chist.html). [Dennis Ritchie](https://en.wikipedia.org/wiki/Dennis_Ritchie "Dennis Ritchie"). [Wikidata](https://en.wikipedia.org/wiki/WDQ_\(identifier\) "WDQ (identifier)") [Q134885774](https://www.wikidata.org/wiki/Q134885774 "d:Q134885774"). Archived from [the original](https://www.bell-labs.com/usr/dmr/www/chist.html) on January 30, 2025 – via Bell Labs/Lucent Technologies. - [Plauger, P.J.](https://en.wikipedia.org/wiki/P._J._Plauger "P. J. Plauger") (1992). *The Standard C Library* (1 ed.). Prentice Hall. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-131509-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-131509-9 "Special:BookSources/978-0-13-131509-9") . [*(source)*](https://github.com/wuzhouhui/c_standard_lib) - Banahan, M.; Brady, D.; Doran, M. (1991). *The C Book: Featuring the ANSI C Standard* (2 ed.). Addison-Wesley. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-201-54433-6](https://en.wikipedia.org/wiki/Special:BookSources/978-0-201-54433-6 "Special:BookSources/978-0-201-54433-6") . [*(free)*](https://github.com/wardvanwanrooij/thecbook) - Feuer, Alan R. (1985). *The C Puzzle Book* (1 ed.). Prentice Hall. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [0-13-109934-5](https://en.wikipedia.org/wiki/Special:BookSources/0-13-109934-5 "Special:BookSources/0-13-109934-5") . - Harbison, Samuel; Steele, Guy Jr. (2002). *C: A Reference Manual* (5 ed.). Pearson. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-089592-9](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-089592-9 "Special:BookSources/978-0-13-089592-9") . [*(archive)*](https://archive.org/details/creferencemanual00harb) - King, K.N. (2008). *C Programming: A Modern Approach* (2 ed.). W. W. Norton. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-393-97950-3](https://en.wikipedia.org/wiki/Special:BookSources/978-0-393-97950-3 "Special:BookSources/978-0-393-97950-3") . [*(archive)*](https://archive.org/details/cprogrammingmode0000king) - Griffiths, David; Griffiths, Dawn (2012). *Head First C* (1 ed.). O'Reilly. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-4493-9991-7](https://en.wikipedia.org/wiki/Special:BookSources/978-1-4493-9991-7 "Special:BookSources/978-1-4493-9991-7") . - Perry, Greg; Miller, Dean (2013). *C Programming: Absolute Beginner's Guide* (3 ed.). Que. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-7897-5198-0](https://en.wikipedia.org/wiki/Special:BookSources/978-0-7897-5198-0 "Special:BookSources/978-0-7897-5198-0") . - Deitel, Paul; Deitel, Harvey (2015). *C: How to Program* (8 ed.). Pearson. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-0-13-397689-2](https://en.wikipedia.org/wiki/Special:BookSources/978-0-13-397689-2 "Special:BookSources/978-0-13-397689-2") . - Gustedt, Jens (2019). *Modern C* (2 ed.). Manning. [ISBN](https://en.wikipedia.org/wiki/ISBN_\(identifier\) "ISBN (identifier)") [978-1-61729-581-2](https://en.wikipedia.org/wiki/Special:BookSources/978-1-61729-581-2 "Special:BookSources/978-1-61729-581-2") . *[(free)](https://gustedt.gitlabpages.inria.fr/modern-c/)* - [ISO C Working Group official website](https://www.open-std.org/jtc1/sc22/wg14/) - [ISO/IEC 9899](https://www.open-std.org/JTC1/SC22/WG14/www/standards), publicly available official C documents, including the C99 Rationale - ["C99 with Technical corrigenda TC1, TC2, and TC3 included"](https://web.archive.org/web/20071025205438/http://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf) (PDF). Archived from [the original](https://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf) (PDF) on October 25, 2007. (3.61 MB) - [comp.lang.c Frequently Asked Questions](https://c-faq.com/) - [A History of C](https://csapp.cs.cmu.edu/3e/docs/chistory.html), by Dennis Ritchie - [C Library Reference and Examples](https://en.cppreference.com/w/c)
Shard152 (laksa)
Root Hash17790707453426894952
Unparsed URLorg,wikipedia!en,/wiki/C_(programming_language) s443