-
Passing Arrays into Functions
In previous two posts we discussed about arrays and functions. In following simple program we will create a function which will accept an array as an input. Furthermore that function will…
-
Arrays in C Programming
Arrays in C Programming: Array is a type of variable which can store multiple items of the same data type. In following simple program we will define an array of…
-
Function Call by Value and Call by Reference in C Programming
In this simple C code example we tried to show the difference between function call by value and call by reference in C programming. In function call by value the…
-
Functions in C Programming – Code Example
For simplicity we divide our code into small pieces / modules known as functions. To use functions in C programming we need to define function prototype, function definition and finally we…
-
How to use for loop in C Programming
For loop is also a type of repetition structure. This repetition structure is simpler in syntax as compared with other 2 loops because all four loop conditions can be…
-
How to use do-while loop in C Programming
Do-while loop is also a type of repetition structure used to repeat statement(s) for certain number of times. The major difference between while and do while loop is that…
-
How to use while loop in C Programming
Sometimes in C program we need to repeat statements for certain number of times. So in order to repeat statements for number of times we use repetition structure in…
-
How to use switch statement in C Programming
Switch statement is also called as multiple selection structure in C Programming. Switch selection structure is similar to if-else selection structure. The difference is instead of using multiple if-else…
-
How to use if-else statement in C Programming
In previous post we discussed about if statement in C Programming. If-else statement called as double selection structure in C Programming. In simple words it says “Do something when a…
-
How to use if statement in C Programming
If statement is called as selection structure in C Programming. If statement checks a condition and proceed further depending upon the fact that whether the condition being checked is…
-
How to define variables in c programming
In our previous post we discussed about how to get values from user. Sometimes we need to define variables and assign values to those variables. This simple program explains how to…
-
How to get value from user in C Programming
Sometimes in a program we need to get values from user, process the values entered by user and print / output the results of that processing on the screen. In…