Tuesday, 4 October 2016

Program to find Comission if sale is given .



#include<iostream.h>
#include<conio.h>
void main ()
{
clrscr();
int comm , sale;
cout<<“Enter sale “;
cin>>sale;
comm = sale<=5000?0:(sale<=12000?3:(sale<=22000?7:(sale<=30000?10:15)));
cout<<“Commision = “<<comm<<“%”;
getch();
}

No comments:

Post a Comment

Basic Implementation of Array as a Pointer

#include<iostream.h> #include<conio.h> void main() { clrscr();   int arr[5];   cout<<"Enter 5 nos. ";   f...