0% found this document useful (0 votes)
2 views2 pages

Introduction To C Language Mobile

C is a general-purpose, procedural programming language developed in the early 1970s, known as the 'mother of all modern programming languages' due to its influence on languages like C++, Java, and Python. It features simplicity, efficiency, and portability, making it suitable for various applications such as system programming and game development. The typical structure of a C program includes preprocessor directives, global declarations, the main function, and statements, with a defined compilation process for execution.

Uploaded by

kishorsomaiya59
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views2 pages

Introduction To C Language Mobile

C is a general-purpose, procedural programming language developed in the early 1970s, known as the 'mother of all modern programming languages' due to its influence on languages like C++, Java, and Python. It features simplicity, efficiency, and portability, making it suitable for various applications such as system programming and game development. The typical structure of a C program includes preprocessor directives, global declarations, the main function, and statements, with a defined compilation process for execution.

Uploaded by

kishorsomaiya59
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Introduction to C Language

C is a general-purpose, procedural programming language developed in


the early 1970s by Dennis Ritchie at Bell Labs. It is often called the 'mother
of all modern programming languages' because many popular languages
such as C++, Java, and Python are based on its concepts.

History of C
The C language was developed as an evolution of earlier languages like B
and BCPL. It was created to build the UNIX operating system. Over time, it
became popular for its simplicity, efficiency, and portability.

Features of C
• Simple and efficient
• Structured programming language
• Portable and machine-independent
• Rich set of built-in operators
• Low-level access through pointers
• Fast execution speed

Structure of a C Program
A typical C program includes the following sections:
1. Preprocessor directives
2. Global declarations
3. main() function
4. Statements and functions

Compilation Process
The steps to execute a C program are:
1. Writing the code
2. Compiling the code
3. Linking
4. Loading
5. Execution

Example 1: Hello World Program


#include <stdio.h>

int main() {
printf("Hello, World!\n");
return 0;
}
Output:
Hello, World!

Example 2: Addition of Two Numbers


#include <stdio.h>

int main() {
int a, b, sum;
a = 10;
b = 20;
sum = a + b;
printf("Sum = %d", sum);
return 0;
}
Output:
Sum = 30

Uses of C Language
• System programming
• Game development
• Embedded systems
• Operating systems
• Compiler design
• Database systems

Conclusion
C language is a foundation for many modern programming languages. It is
efficient, portable, and powerful, making it ideal for both beginners and
professionals.

You might also like