C Language Notes

Topics: C, Variable, Programming language Pages: 24 (5409 words) Published: April 19, 2011

Some words about Computer Programming languages
Naturally a language is the source of communication between two persons, and also between person to machine like computer. The languages we can use to communicate with the computer are known as Computer programming languages. Generally there are two major types of languages are available are as follows: 1. Low level languages

2. The set of commands available in low level is complex and not easy to understandable. In this category " Assembly " and " machine codes " are available. Assembly programs are faster than other high-level language programs. 3. High level languages

• The set of commands available in high level language is very simple and easy to understandable. High level languages are further divided into two major categories. 1. Procedure Oriented language

2. In this category we are able to create our project or programs using procedural approach means in this type we can able to divide our big project/program into small subroutines or procedures. After making procedures we can able to call a ‘procedure’ one or more places. The lists of procedural languages are as follows:

C language
C++ (Object Oriented)
Java (Objected Oriented)
Smalltalk (Objected Oriented)
Pascal language
3. Non-Procedural Languages: This category also known as ‘Problem Oriented languages’. In this type of languages we can able to make program only at specific range like database. The followings are the examples of Non procedural languages 1.

1. SQL (Structured Query Language)
2. SNOBOL (String processor)
C LanguageHistory
• Developed at Bell Laboratories. first standard version release in 1972. • Developed by Dennis Richee.
• Before c a Programming language is very popular in those days the name of the language is B-Language so the developers decided the name of ‘C’ language because C is next to B. The Integrated Development Environment (IDE):

Turbo c features as integrated Development environment, or IDE,. It is also referred to as the programmer’s platform.) in IDE you can able to write/save/open your programs or code, compile using short cut keys, and also perform code debugging very easily. IDE

Common Short cut Keys Description
F2 press to Save current work
F3 press to open an existing file
ALT-F3 press to close current
ALT-F9 press to compile only
ALT-F5 press to view the desired output of the program.
CTRL-F9 press to compile+run
ALT-X or ALT-F-X press to exit from TC IDE
• C Programs Skeleton (General)

< Global Variable (on your demand)>
main () (Necessary)
{ statements }
< function definition>
{ }
Remember Some common rules for writing C program
• Use all commands or statements in lower or small case. • After completion of a statement excluding main() or loops must insert ; (semicolon) as a statement terminator. • Don’t use/declare identifier or variable name same as statement name suppose int include; this is a wrong statement because include has a special meaning in the language. • Header Files or Preprocessor Directives contains references or links of library functions. That is built-in in the C language. Suppose if you want to use a function clrscr() ; in the main function so must be declared on top # include other wise you could have an prototype error. Some header files are as follows

And many more header files are available in C…
void main(void)
Every C programs consists of one or more functions. No matter how many functions there are in a C program , main is the one to which control is passed from the operating system when the program is run ; it is the first function executed. The word "void" preceding "main" specifies that the function main() will not return a value. The second "void,"...
Continue Reading

Please join StudyMode to read the full document

You May Also Find These Documents Helpful

  • C LANGUAGE Essay
  • C++ Notes Essay
  • C Language Essay
  • C++ Notes Essay
  • Introduction to the C# Programming Language Essay
  • Basic 'C' Language Essay
  • C Language: Question Bank Research Paper
  • Interview Question on C Language Essay

Become a StudyMode Member

Sign Up - It's Free