felippegh / orange-shop

A simple Python application to help you manage your own Orange Shop(that sometimes sells apples too). :)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Orange Shop

You own an orange store, you want to have “n” number of containers with “m” amount of oranges that can hold. It must allow the sale of oranges (you define the price per orange) and check the shelves after each sale. The oranges that are sold must be in order, for example, there are 3 shelves, the shelf most to the right is the one that always has priority, and the oranges to the left of this, move to the nearest right to avoid let them get bad at a certain point, you should be able to sell apples, applying the same rules as above. if a shelf of oranges is empty, and there are no oranges left, it'll be filled with apples

Your solution should allow, only to define the number containers, the amount per container and the price per orange. You can simulate the sells, or allow an input to sell oranges and apples.

Requirements

  • Python 3.x

Setup instructions

Execute the following steps:

  • Enter in the project folder
  • Run python3 orange-shop.py

About

A simple Python application to help you manage your own Orange Shop(that sometimes sells apples too). :)

License:MIT License


Languages

Language:Python 100.0%