if the total selling price of 15 items and the total profit
earned on them is input through the keyboard, write a program
to find the cost price of one of the item

Answer Posted / gagan kumar

void main()
{
int sell_pr, profit, cost_pr, cost_pr_one_item ;
clrscr();
printf(“Please enter the selling price of 15 items:”);
scanf(“%d”, &sell_pr);
printf(“Please enter the profit earned on 15 items:”);
scanf(“%d”, &profit);
cost_pr = sell_pr – profit;
cost_pr_one_item = cost_pr/15;
printf(“Cost price of one item is %d”, cost_pr_one_item);
getch();
}

Is This Answer Correct ?    6 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Does c have circular shift operators?

722


What is array in c with example?

610


Explain union. What are its advantages?

611


Why we use void main in c?

587


What is the modulus operator?

729






Explain can you assign a different address to an array tag?

636


How do I copy files?

619


Does c have enums?

594


How to compare array with pointer in c?

615


What is union in c?

629


What is ambagious result in C? explain with an example.

2049


Write a program to reverse a string.

631


how do you programme Carrier Sense Multiple Access

1510


What is sizeof int?

629


What would be an example of a structure analogous to structure c?

570