Skip to main content

Header Files

 Header  files  in  the  program  are  included  before  main ( )  function between < > after writing #include as shown in above examples #include <stdio.h> is written. All header files are present in compiler  if  you  are  using  TurboC  then  you  can  see  this  in  INCLUDE  folder “C:\TurboC++\Disk\TurboC3\INCLUDE” there are so many header files are present this are named along with .h. in chapter header files we will see how to create your own header file.

Examples of header files: stdio.h, conio.h, math.h, graphics.h, string.h, io.h, malloc.h and so on. You don’t need to memorize all header files basically in this book we are going to use only 4-5 header files.
A header file is  a file with extension .h which contains  C function declarations  and macro 
definitions and to be shared between several source files. 

Let’s see in short some header files:
  1. stdio.h: It means Standard Input Output (stdio) header file in which output function printf () is defined  and  scanf ()  for  getting  input  from  user. Like just  like  that  there  are  so  many functions are defined.
  2. Conio.h: It means Console Input / Output (con Io) header file in which the functions like clrscr() use for clear output screen and getch () to hold output screen up to get one input from keyboard. And getche () to hold output screen after get one input from keyboard.
  3. Math.h: defines mathematical functions like sin (), cosine (), tan (), pow () and so on.
  4. Graphics.h: For graphics functions for antinational functions, there are some functions to draw circle, ellipse, line, rectangle, to colour screen on output screen. We will see this in chapter C Graphics


Popular posts from this blog

Why should I learn Computer language (Programming)? And why C language good for beginners?

1. Software is the spirit  ( आत्मा )  of hardware . 2. Just by joining some hardware (Electronics  Components) we can’t make our  Computers, Laptops, Mobiles, Tablets, etc. so programming is essential to make this hardware functional. 3. Program instructs and controls the hardware and C is the very basic language to start. 1. By learning a computer language you'll able to build your own software, OS, Virus, Antivirus. For example, WhatsApp, Hike, Calculator,  Media  Player, Facebook, Twitter. 5. After learning the C language you'll be able to build your own computer applications. 6. C language Helps to learn more advanced languages like Java, Dot Net, MATLAB. because this all language depends upon C language. 7. It is good for starters because it is just like the English language and easy to understand.

C-Compiler for Mobile Phone

Run your C language programs on Android Mobile I hope you may aware of the C language compiler. For more information, you may visit on Compilers Page  on my blog. So many C language programmer uses Android but they are not aware of they could run their programs on their phone itself. Even I had the same problem in my first year of Engineering. C-Compiler for Android Mobile Cpp Droid CppDroid is a mobile application that provides an environment to run your C language program this app is installed by  500,000 - 1,000,000  from google play. Download Cpp Droid from here   Steps to run program in CppDroid: Step 1: Download and install CppDroid from play store step2: Open CppDroid step 3: Go to Editor step 4: Type a program step 5: save it as .c extension step 6:  Click on run step 7:Output

Constants and Variables in C

  Constants in C : Constants are the terms that can't be changed during the execution of a program. Examples : Integer Constants: 0, 1, 2, 3, 4, 5, 6, 7 . . . . . . . Floating Constants : 0.0, 0.1, 0.2, 0.3, -0.4, 0.5, 5.1546, 2.5465, -1.02545 . . . . . . .  Character  Constants :  Character  constants  are  the  constant  which  use  single  quotation  around  characters. For example: 'a', 'l', 'm', 'F' etc. Variables in C: Variables are memory location in computer's memory to store data. To indicate the memory location, each variable should be given a unique name called identifier. Variable names are just  the  symbolic  representation  of  a  memory  location.  Examples  of  variable  name:  ABC,  var_no, var_123, Var123, Count etc. Basic Data Types in C:  Char : a single byte that can hold a character (‘a’, ’b’, ’c’, ’d’, ’e’ . . . . . . . )  Int : An Integer can hold 2 or 4 byte integers (0, 1, 2, 3, 4, 5, 6, 7 . . . . . . .) Float : A float