Blogspot - free-c-programs.blogspot.in - C++ & C Programs with output | Free C Programs

Latest News:

Write a program to create a linear linked list interactively and print out the list and the total number of items in the list 27 May 2013 | 11:13 am

#include #include #define NULL 0 struct linked_list { int number; struct linked_list *next; }; typedef struct linked_list node; /* node type defined */ main() { node *head; void create(node *p); int...

Find 2’s complement of a binary number 27 May 2013 | 10:50 am

#include #include void complement (char *a); void main() { char a[16]; int i; clrscr(); printf("Enter the binary number"); gets(a); for(i=0;a[i]!='\0'; i++) { if (a[i]!='0' && a[i]!='1') { printf("T...

Implement Trapezoidal Method 27 May 2013 | 10:47 am

#include #include #include char postfix[80]; float stack[80]; char stack1[80]; int top=-1,top1=-1; float eval(char postfix[], float x1); void infix_postfix(char infix[]); main() { float x0, xn, h...

Calculate the cost of publishing conference 27 May 2013 | 10:28 am

#include #include #include #include const int std_size=15; const float std_cost=5; const float penalty=0.5; class paper; float totalcost(paper*,int); class paper { char author[25]; int page; publi...

Area of two triangles - CPP Program 27 May 2013 | 09:54 am

#include #include #include class right_triangle { double base; double height; public: void initialize(double,double); double area(); double peri(); }; void right_triangle::initialize(double b, doub...

Income Class in C++ 27 May 2013 | 09:44 am

#include #include class income { double BS; double DA; public: void initialize(double,double); double pay_sal(); double deduction(); double calc_tax(); void income_detail(); }; void income::initiali...

Example of Stack in C++ 27 May 2013 | 09:39 am

#include #include const int size=10; class stack { int arr[size]; int top; public: void initialize(); void push(int); int pop(); int stack_top(); void show(); }; void stack::initialize() { top=-1; }...

Complex number 27 May 2013 | 09:37 am

#include #include class complex { float real; float imag; public: void getnum(); void putnum(); void sum(complex,complex); void dif(complex,complex); }; void complex::getnum() { cout >real; cout >im...

Find Prime Factor of number 1 Feb 2013 | 10:18 pm

/*Program to find out prime factors of a given number.*/ #include #include void main() { int number; printf("Enter a number "); scanf("%d",&number); printf("\nThe prime factors of %d are:",num...

Find Generic root of number 1 Feb 2013 | 10:15 pm

#include int main() { int num,i; printf("Enter any number: "); scanf("%d",&num); printf("Generic root: %d", (i = num % 9) ? i : 9); return 0; }

Recently parsed news:

Recent searches: