Computer Science, asked by shadowkingt0321, 1 month ago

4. WAP to accept price of an item and discount percentage. Calculate the price of
item after discount.

Answers

Answered by sandipan2224
1

Answer:

C++ solution:

#include<iostream>

using namespace std;

int main(){

   int price, disc;

   cout<<"Enter price of item: ";

   cin>>price;

   cout<<"\nEnter discount percentage: ";

   cin>>disc;

   cout<<"\nPrice of item after discount is: ";

   cout<<price - (double)(price*disc)/100;

}

Hope this helps you.

Similar questions