Hye........
plzzz solve my problem my problem is that in this progamme
is runing but i dont understand that how in the end of the programme there is some thinds are missing that are
when programme finished then it print the
Thanks for using the program.
and this progamme is runinig in this way
for example
The program should also have a menu like.

Addition : A
Subtraction : S
Power : P
Factorial : F
Quit : Q

Please enter the option:

The program should repeat until the user wants to quit.

Sample Output

Please enter the first number: 11
Please enter the second number: 3

Addition : A
Subtraction : S
Power : P
Factorial : F
Quit : Q

Please enter the option: A

The Result after Addition is: 14

Do you want to continue? Y
//After clearing the text window
Addition : A
Subtraction : S
Power : P
Factorial : F
Quit : Q


Please enter the option: S

The Result after Subtraction is: 8
Do you want to continue? Y
//After clearing the text window
Addition : A
Subtraction : S
Power : P
Factorial : F
Quit : Q

Please enter the option: P

The Result after taking Power is: 1331

Do you want to continue? Y
//After clearing the text window
Addition : A
Subtraction : S
Power : P
Factorial : F
Quit : Q


Please enter the option: Q

Thanks for using the program.

but that i have make it but there is many problems
plzzzzzzzz can u help me in this problem
BYE take crae
bye

THE ORGRAMME IS

#include<iostream.h>     
#include<conio.c>  

char choice;
int time1;
int time2;
char cnt;
int result;
//**********************************************************
int Power(int time1, int time2)
{
    int exponentResult=1;
    for(int i=0 ; i<time2 ; i++)
        exponentResult=time1 * exponentResult;
    return exponentResult;
}
//***************************************************************
void Factorial(int time1, int* factorialResult)
{
    *factorialResult=1;
    for(int i=time1 ; i>0 ; i--)
        *factorialResult=*factorialResult * i;
}
/******************************************************************/
                       int sum (int time1, int time2)
{
int sum;
sum = time1 + time2;
return sum;
}
/******************************************************************/
                     int multiply(int time1, int time2)
{
 int multy;
multy = time1 * time2;
return multy;
}
/****************************************************/
int main()
{ 
do
{
    cout<<"\n Enter first number: ";
    cin>>time1;    
    cout<<"\n Enter second number: ";
    cin>>time2;   
    cout<<"\n\tEnter S for Sum\n";      
    cout<<"\tEnter V to find power\n";          
    cout<<"\tEnter A to Multiply\n"; 
    cout<<"\tEnter F for the factorials\n";     
    cout<<"\tEnter Q to Quit\n";  
    cout<<"\n\tPlease enter the option: ";
    cin>>choice;        
switch (choice)
{
    case 's':
    cout<<" Result after addition is : "<<sum(time1, time2)<<endl;
    break;
    case 'a':
    cout<<" Result of Multiply first & second : "<<multiply(time1, time2)<<endl;
    break;
    case 'v':   
    cout<<" Result of power integers is : "<<Power(time1,time2)<<endl;
    break;
    case 'f':
    Factorial(time1,&result);
    cout<<endl<<"The result of factorail of first number is :     "<<result;
    Factorial(time2,&result);
    cout<<endl<<"The result of factorail of Second number is :     "<<result;
    break;
    case 'q':
    exit(0); 
    break;
  if(choice == 's' || choice == 'v' || choice == 'a' || choice == 'f' || choice == 'q') 

    default:    
    cout<<"\nwrong choice entered\n";
    break;
   }
    cout<<"\nDo you want to continue? Y: ";
    cin>>cnt;
    }
while(cnt == 'y');
clrscr();
getch();
}

Use [code][/code] tags.

#include<conio.c>

->

#include<conio.h>
if(choice == 's' || choice == 'v' || choice == 'a' || choice == 'f' || choice == 'q') 

default: 
cout<<"\nwrong choice entered\n";
break;

What are you trying to do there?

BTW, the standard C function pow() is pretty much the same as

int Power(int time1, int time2)

#include<stdio.h>
#include<conio.h>
void main()
{
int A,S,a,b;
long int F=1;
clrscr();
printf("enter two number");
scanf("%d%d",&a,&b);
A=a+b;
printf("\nA=%d",A);
S=a-b;
printf("\nS=%d",S);
for(i=1;i<=a;i++)
{
F=F*i;
}
printf("\nthe factorial first number F(a)=%ld",F);

for(i=1;i<=b;i++)
{
F=F*i;
}
printf("\nthe factorial of second number F(b)=%ld",F);
getch();
}

commented: 3 YEARS too late, no code tags, no explanation, void main .... -6
commented: Taste It -2

include <math.h>

done == yes

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.