CSE

Welcome To Computer Science & Engineering. This Site Contains Complete Information of Computer Engineering, Computer Science & Engineering, Computer Information System, Software Engineering, Computer Science Course Schedule, Course Tutorial, Suggestions, University Tuition Fees, Study Guideline & More.

Introduction to C Programming

Introduction to C Programming

C is a general-purpose computer programming language developed in 1972 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system. C is a structured programming language, which means that it allows you to develop programs using well-defined control structures (you will learn about control structures in the articles to come), and provides modularity (breaking the task into multiple sub tasks that are simple enough to understand and to reuse). C is often called a middle-level language because it combines the best elements of low-level or machine language with high-level languages.  
Where is C useful?
C’s ability to communicate directly with hardware makes it a powerful choice for system programmers. In fact, popular operating systems such as Unix and Linux are written entirely in C. Additionally, even compilers and interpreters for other languages such as FORTRAN, Pascal, and BASIC are written in C. However, C’s scope is not just limited to developing system programs. It is also used to develop any kind of application, including complex business ones. The following is a partial list of areas where C language is used: 
Ø       Embedded Systems 
Ø       Systems Programming
Ø       Artificial Intelligence

Ø       Industrial Automation
Ø       Computer Graphics
Ø       Space Research

Why you should learn C? 

You should learn C because:
·                C is simple.
·          There are only 32 keywords so C is very easy to master. Keywords are words that have special meaning in C language.
·             C programs run faster than programs written in most other languages.
·            C enables easy communication with computer hardware making it easy to write system programs such as compilers and interpreters.
WHY WE NEED DATA AND A PROGRAM
Any computer program has two entities to consider, the data, and the program. They are highly dependent on one another and careful planning of both will lead to a well planned and well written program. Unfortunately, it is not possible to study either completely without a good working knowledge of the other. For that reason, this tutorial will jump back and forth between teaching methods of program writing and methods of data definition. Simply follow along and you will have a good understanding of both. Keep in mind that, even though it seems expedient to sometimes jump right into coding the program, time spent planning the data structures will be well spent and the quality of the final program will reflect the original planning
How to run a simple c program
1.  Copy Turbo c/c++ in computer
2.  Open c:\tc\bin\tc.exe
3.  A window appears
4.  Select File->new to open a new file
5.  Type the following program on editor

#include <stdio.h>
void main()
{
            printf(“hello”);
}

6. compile the program by pressing ALT+F9
7. Run the program by pressing CTRL +F9
Note:
1. C is case sensitive
2. Always terminate statements with semicolon.
3. A program starts with main()


No comments:

Post a Comment

Watch Thousands New Movie

Search This Blog

free counters