Computer Science, asked by prerakjhala32, 5 months ago

Design a class sample for the following functions to print cash memo for a product from a shop
i) void product (): create this function with product code(integer) , unit price of product (float) and quantity of product(float) as parameters or arguments. Calculate total cost of the product, discount as 12% on total cost and net price to be paid for the product.

(ii) void run(): to invoke function product() by passing required values to this function and print all the data members including total discount and net price of product with suitable messages.​

Answers

Answered by dhilipan790
0

Answer:

Specify the class Check with following overloaded functions:

void compare (int x, int y): to compare and print smallest from x, y. If both the numbers are same then print suitable message.

void compare(char, char): to compare the numeric value of the two characters with higher numeric values. If both characters are same then print any one of them.

Similar questions