Skip to content

aminmgk/Python_Algorithm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

Python Shop Algorithm

This project demonstrates a Python-based program to simulate the ordering process in a shop selling mobile devices, SIM cards, and accessories. The program is designed to:

Prompt for user input with validation to ensure correct entries. Use clear error messages and output. Store item codes, descriptions, and prices in appropriate data structures.

program algorthm shop png

Features

Task 1: Setting up the System

Creating the foundational structure of the shop, allowing users to:

Select a specific phone or tablet. Choose whether a phone is SIM Free or Pay As You Go. Select a standard or luxury case. Choose the chargers required (none, one, or both). Calculate the total price for the transaction. Output a list of the items purchased and the total price.

Task 2: Ordering Multiple Mobile Devices

Extending the initial setup by:

Offering the customer the option to purchase additional mobile devices. Performing the same steps as Task 1 for each additional mobile device. Calculating a running total for the customer. Providing a final output of the total cost once no further devices are required.

Task 3: Offering Discounts

Adding a discount feature:

Apply a 10% discount on the price of each additional phone or tablet purchased. Output the new total the customer will need to pay. Display the amount of money saved from the discount.

Running the Program

  1. Clone the repository to your local machine.
  2. Run the Python script to start the program.
  3. Follow the on-screen prompts to complete the required tasks.
  4. Choose a task (Task 1, Task 2, or Task 3) based on the desired functionality.
  5. Enter your selections according to the prompts to complete the shopping process.
  6. View the final output for the total cost and other details.

Runing the program will simulate a shopping experience for mobile devices, incorporating the various options and functionalities described in the tasks.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages