C program to add two numbers

C program to add two numbers: This c language program perform the basic arithmetic operation of addition on two numbers and then prints the sum on the screen. For example if the user entered two numbers as 5, 6 then 11 (5 + 6) will be printed on the screen.

C programming code

int main()
   int a, b, c;
   printf("Enter two numbers to add\n");
   c = a + b;
   printf("Sum of entered numbers = %d\n",c);
   return 0;

C programming examples

These programs illustrate various programming elements, concepts such as using operators, loops, functions, single and double dimensional arrays, performing operations on strings, files, pointers etc. 
Browse the code from simple c program to complicated ones you are looking for, every one of them is provided with output. 
C program download with executable files, so that you save on your computer and run programs without compiling the source code. All programs are made using c programming language and Codeblocks, most of these will work under Dev C++ compiler also. 
The first program prints "Hello World" on screen.

  1. Hello World
  2. Print Integer
  3. Addition
  4. Odd or Even
  5. Add, Subtract, Multiply and Divide 
  6. Leap year
  7. Factorial
  8. HCF and LCM
  9. Add n numbers
  10. Swapping
  11. Reverse number
  12. Palindrome number
  13. Print Pattern
  14. Prime numbers
  15. Find Armstrong number
  16. Fibonacci series

C program print integer

This c program first inputs an integer and then prints it. 
Input is done using scanf function and number is printed on screen using printf.
In c language we have data type for different types of data, for integer data it is int, for character date char, for floating point data it's float and so on.

C programming code

int main()
  int a;
  printf("Enter an integer\n");
  scanf("%d", &a);
  printf("Integer that you have entered is %d\n", a);
  return 0;

C hello world program

C hello world program: c programming language code to print hello world. This program prints hello world, printf library function is used to display text on screen, '\n' places cursor on the beginning of next line, stdio.h header file contains declaration of printf function. 
The code will work on all operating systems may be its Linux, Mac or any other and compilers. To learn a programming language you must start writing programs in it and may be your first c code while learning programming.

Hello world in C language

//C hello world example
int main()
  printf("Hello world\n");
  return 0;
Purpose of Hello world program may be to say hello to people or the users of your software or application.

Computer Network : Mesh Network Topology

Mesh topologies involve the concept of routes. Unlike each of the previous topologies, messages sent on a mesh network can take any of several possible paths from source to destination. (Recall that even in a ring, although two cable paths exist, messages can only travel in one direction.) Some WANs, most notably the Internet, employ mesh routing.
A mesh network in which every device connects to every other is called a full mesh. 
The mesh network topology employs either of two schemes, called full mesh and partial mesh. In the full mesh topology, each workstation is connected directly to each of the others. In the partial mesh topology, some workstations are connected to all the others, and some are connected only to those other nodes with which they exchange the most data.

Computer Network : Tree Network Topology

Tree topologies integrate multiple star topologies together onto a bus. In its simplest form, only hub devices connect directly to the tree bus, and each hub functions as the root of a tree of devices. This bus/star hybrid approach supports future expandability of the network much better than a bus (limited in the number of devices due to the broadcast traffic it generates) or a star (limited by the number of hub connection points) alone.
This topology divides the network in to multiple levels/layers of network. Mainly in LANs, a network is bifurcated into three types of network devices. The lowest most is access-layer where user’s computer are attached. The middle layer is known as distribution layer, which works as mediator between upper layer and lower layer. The highest most layer is known as Core layer, and is central point of the network, i.e. root of the tree from which all nodes fork.