20120113

Program in C to calculate average of marks in an array

//Program in C to calculate average of marks in an array
#include<stdio.h>
int main()
{
        int i,sum=0,avg;
        int  marks[5];
        printf("\n Enter marks for 5 ppl:\n");
        for(i=0;i<5;i++)
        {
        scanf("%d",&marks[i]);
        }
        for(i=0;i<5;i++)
        {
        sum=sum+marks[i];
        }
        avg=sum/5;
        printf("\n svg is =%d",avg);
}


Simples Way to learn Data Structure in C++ CPP or C


C++ Program for Circular Queue implementation using linked list
 
C++ program for Circular Queue implementation using Array

C++ program for reversing single Linked list nodes 

C++ Program for sorted single linked list with class

C++ Program for BST-Binary Search Tree   

2 comments:

  1. Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    Program in C/C++/CPP to calculate average of marks in an array

    ReplyDelete
  2. Program in C/C++/CPP to calculate average of marks in an array
    Program in C/C++/CPP to calculate average of marks in an array
    Program in C/C++/CPP to calculate average of marks in an array
    Program in C/C++/CPP to calculate average of marks in an array

    ReplyDelete