Sign Up

Have an account? Sign In Now

Sign In

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here
Sign InSign Up

SIKSHAPATH

SIKSHAPATH Logo SIKSHAPATH Logo

SIKSHAPATH Navigation

  • Home
  • Questions
  • Blog
    • Computer Science(CSE)
    • NPTEL
    • Startup
  • Shop
    • Internshala Answers
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Questions
  • Blog
    • Computer Science(CSE)
    • NPTEL
    • Startup
  • Shop
    • Internshala Answers
Home/Questions/Q 18629
Next
In Process
Hacker
  • 0
Hacker
Asked: June 12, 20222022-06-12T01:28:23+05:30 2022-06-12T01:28:23+05:30In: C++

Shoprite is a grocery shop that has outlets nationwide. They …

  • 0

Shoprite is a grocery shop that has outlets nationwide. They give discounts to customers who buy products in bulk. For a given number of products their discounts are as follows:
Quantity              Discount
0 – 20                   No discount
More than 20     10%
More than 30     15%
More than 40     20%
More than 50      30%
They are planning to get a computerised system which automates calculation of total amount due for a given number of products.

1 Based on the above scenario, design a solution for Shoprite using a flowchart.

2 Based on the outcome of Question 3.1, create a C++ program using Visual Studio. Your program must enter the quantity of products then compute the discount based on the quantity and output the total amount due.

  • 1 1 Answer
  • 128 Views
  • 0 Followers
  • 0
Answer
Share
  • Facebook

    1 Answer

    • Voted
    • Oldest
    • Recent
    1. I'M ADMIN
      2022-06-12T12:52:07+05:30Added an answer on June 12, 2022 at 12:52 pm

      If you have not followed us yet, follow us on insta for collaboration and promotion.

      Follow us on Social Media
      telegram instagram

       

      CODE:

       

      //VISIT SIKSHAPATH.IN FOR MORE
      #include<iostream>
      using namespace std;
      
      int main()
      {
      int qty,price;
      float discount,total;
      cout<<"Enter Quatity:";
      cin>>qty;
      cout<<"Enter the Price:";
      cin>>price;
      if(qty<20)
      discount=0;
      else if(qty<30)
      discount=0.1;
      else if(qty<40)
      discount=0.15;
      else if(qty<50)
      discount=0.2;
      else
      discount=0.3;
      total=qty*price;
      discount=discount*total;
      cout<<"Total amount used:"<<total<<endl;
      cout<<"Eligibile discount:"<<discount<<endl;
      total=total-discount;
      cout<<"Grand Total:"<<total<<endl;
      }
      • 0
      • Reply
      • Share
        Share
        • Share on WhatsApp
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn

    Leave an answer
    Cancel reply

    You must login to add an answer.

    Forgot Password?

    Need An Account, Sign Up Here

    Sidebar

    Stats

    • Questions 1k
    • Answers 1k
    • Posts 138
    • Best Answers 65
    • NPTEL Python for Data Science Assignment 1 Answers 2023
    • NPTEL Solution: Cloud Computing Assignment 2 Answers 2023
    • Solution Revealed: NPTEL Programming in Java Week 1 Assignment 2023
    • NPTEL Joy of Computing Using Python Assignment Answers Week 1 2023
    • NPTEL Cloud Computing Assignment 1 Answers 2023

    Popular Questions

    • I'M ADMIN

      Internshala ethical hacking final test answers: Question sequence differs but ...

      • 6 Answers
    • AK

      You have a green lottery ticket, with ints a, b, ...

      • 4 Answers
    • mj

      Solve by Gauss Elimination Method 5x+y+z+w=4 ,x+7y+z+w=12 , x+y+6z+w=-5, x+y+z+4w=-6

      • 3 Answers

    Explore

    • About Us
    • Account
    • Answers
    • Badges
    • Billing Information
    • Blog
    • Cart
    • Categories
    • Checkout
    • Checkout Page
    • Comments
    • Contact
    • Delivery Policy for Sikshapath
    • Disclaimer
    • FAQs
    • Home
    • Login
    • Membership Levels
    • Membership Login
    • My Account
    • My account
    • Privacy Policy Notice
    • Profile Edit
    • Questions
    • Questions Feed
    • Refund/Cancellation Policy
    • Search Results
    • Shop
    • Sign Up
    • SikshaPath Web Stories
    • Sitemap
    • TERMS OF USE
    • Thank You
    • Welcome

    Footer

    Helpful Links

    • Disclaimer
    • Privacy Policy Notice
    • TERMS OF USE
    • FAQs
    • Refund/Cancellation Policy
    • Delivery Policy for Sikshapath

    Follow

    © 2021-2022 Sikshapath. All Rights Reserved

    Insert/edit link

    Enter the destination URL

    Or link to existing content

      No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.