Inkers is a provider of a toner and inkjet printer cartridges (generic or compatible). They provide high quality ink cartridges for your Laser printer, Inkjet printer, multifunction printer and fax machines.They says "One best thing to purchase from...
Mar 30, 2007
Mar 26, 2007
C++ program for Password input and check
C++ program to input and check a given password. if user input a correct password then program to add two number will be executed and a user input a wrong password. A message "Wrong password" would appeared on the screen and terminates the proram.#include<iostream.h>#include<conio.h>main(){clrscr();for...
Inheritance In C++
C++ program to demonstrate inheritance :#include<iostream.h>#include<conio.h>class demo1 // base class{public :void hello(){cout << "hello FROM DEMO1" <<endl;}};class demo2 : public demo1 // derived class{public :void hi(){cout...
Function Overloading in C++
Function overloading : two or more than two function in a program with same name but must be different in parameters.#include<iostream.h>#include<conio.h>class demo{public :void add(){int a,b,c;cout <<"enter any number";cin >>...
File Handling in C++
File handling : to store data in a text/data fileWriting data to a text file#include<iostream.h>#include<conio.h>#include<fstream.h> // file streammain(){clrscr();char name[10];int salary;ofstream f("unique"); // output file stream...
Exit() function in C++
exit function : is terminates entire program. Here it is used in for loop when the value of i is eqauls to 100 then exit(0) will be executed and the program will be terminated.#include<iostream.h>#include<conio.h>#include<process.h>...
Mar 23, 2007
Default Argument Function in C++
default argument function : In this program function add have two parameters and one of them is default argument and has fix value 10. if this argument is passed when calling this function default value of the function will be omited. If this value...
Destructor in C++
destructor : is a member function of a class. it has same name as a class. followed by a tilde sign ~ it does not have return type (neither int nor void) . it automatically get executed when object is destroyed.#include<iostream.h>#include<conio.h>class...
Constructor in C++
// constructor : is a member function of a class. it must have same name// as a class. it does not have any return type neither int nor void.// it automatically get executed when object is created. it is used to// initialize variables.#include<iostream.h>#include<conio.h>class...
Mar 20, 2007
IF condition in C++
IF condition : condition is formed after if keyword in a bracket.if condition is satisfies then only statement within if block will be executed, if condition fails then statement within IF block will not be executed. if there is only one statement within...
C++ class program (function with return value)
C++ class program (function with return value)#include<iostream.h>#include<conio.h>class student // student is a class{public :int add(int a,int b){int c;c=a+b;return c;}};main(){clrscr();student s1;int a,b;cout <<"enter any number";cin...
Function with parameter in a class
C++ (OOP) object oriented programmingfunction with parameter in a class.#include<iostream.h>#include<conio.h>class student{public :void add(int a,int b){int c;c=a+b;cout << c <<endl;}};main(){clrscr();student s1;int a,b,c;cout...
Functions or Methods in a class
C++ (OOP) object oriented programmingfunctions in a class : functions in a class are known as methods or member functions#include<iostream.h>#include<conio.h>class student // student is a class{public :void add() // member function{int a,b,c;cout...
C++ program to demonstrate class and object (OOP)
class : class is a template for an object. (master copy)object : object is an instance of a class. (photo copy)members of the class are by default private. private means members can not be accessible from anywhere in the prgraom excpet where it is defined.This...
C++ program to input a character
This program will accept a character from the keyboard and display it along with hello.#include<iostream.h>#include<conio.h>main(){clrscr();char z;cout << "enter any character";cin >> z;cout << "hello :";cout << z...
C++ program to demonstrate single dimensional array
This program will accept qnantity of item and rate and calculate total amount and net amount.#include<iostream.h>#include<conio.h>main(){clrscr();int q[3],p[3],tot[3];int net =0;for(int i=0;i<=2;i++){cout<<"ENTER QUANT. OF ITEMS...
Mar 19, 2007
Type anywhere in the Microsoft word document
You can type anywhere in the Microsoft word document simply double click the page area where you want to type. Before doing this make sure that you are working in Page Layout or Web layout view. This facility will work Microsoft 2000 or higher versi...
C++ Program to input/output a matrices
this program will take input for two 3x3 matrices m and n and then print them in matrix format and then it will add two of the matrix and store the result in third matrix (o).#include<iostream.h>#include<conio.h>main(){clrscr();int m[3][3];...
C++ Program to design a admission form using Graphics
#include<iostream.h>#include<conio.h>#include<graphics.h>main(){int driver,mode;driver=DETECT;initgraph (&driver,&mode,"");moveto(250,2);settextstyle(1,HORIZ_DIR,4);outtext("B A B A");line(205,38,420,38);moveto(200,40);settextstyle(1,HORIZ_DIR,2);outtext("COMPUTER...
C++ Program to demonstrate single dimensional array
array : array is a group of elements of same data types. single dimensional array. this program will accepts 5 students marks and store them into an array m and then it will total them. array always start with 0. means first element always be 0.#include<iostream.h>#include<conio.h>main(){clrscr();int...
C++ Program to input age to find out teen, young or old

This program will accept age from the user and according to age appropriate message would be display like baby , child , teenager, young or old. In this program I have used Logical operator (and operator)#include<iostream.h>#include<conio.h>main(){clrscr();int...
C++ program to add, subtract, multiply and divide two given numbers
#include<iostream.h>#include<conio.h>main(){clrscr();int a,b;cout <<"enter any number";cin >> a;cout <<"enter any number";cin >> b;int c=a+b;cout << c <<endl;int d=a-b;cout << d <<endl;int e=a*b;cout...
C program to add two given numbers

In C language how to add two given integer numbers I will show you this by a simple example.It will add two integer values. Every C program must have a main() function. then your program will be in starting curly bracket { and } ending curly bracket....
Mar 13, 2007
C++ program to draw concentric circles

C++ program to generate concentric circles. Here For loop will give radius (i) to circle function and each time it will increment by 5.Delay function will slow down the process to print the concentric circles on the screen. For initgraph() function and...
Mar 12, 2007
C++ program to generate 10 random numbers between 1 to 100

C++ program to generate random numbers between 1 and 100. For random() function, stdlib.h header file is required. randomize() function will generate different random numbers each time you run the program. If you don't include radomize() function it...
Mar 7, 2007
What is an action in Photoshop?
Actions are set of commands that you have to record once and playback any number of times according to your need. Just suppose you have 100 photographs and you want to change the size of all of the photographs so you can create an action of if and apply...
Mar 5, 2007
C++ Program to count vowels in given string

C++ program to count vowels in a string. This program will ask user to input a string of maximum 40 characters and then it will count vowels in the given string.#include<iostream.h>#include<conio.h>#include<stdio.h>main(){int i;clrscr();char...
C++ Program to find out largest of three given numbers

C++ program to find out largest of three given numbers. The program will accept three numbers and then print the largest of three numbers. In this program if statement is used with and (&&) operator.#include<iostream.h>#include<conio.h>main(){clrscr();int...
C++ Program to count uppercase, lower case and numbers in given string

C++ program to count upper case, lower case and numbers in given string. This program will accept a string. then it will count uppercase alphabets(capital letters), small alphabets (lower case letters) and numbers too. Type this in your favourite C++...
Mar 2, 2007
C++ program to generate a table from any given number upto any given number
// or C++ program to generate a table between a given range.// in this program there will be two input num1 and num2 and table will be// generated between given num1 and num2.#include<iostream.h>#include<conio.h>main(){clrscr();int num1,num2;cout...
Subscribe to:
Posts (Atom)