secret auction project in python
secret auction project in python
Note : Recplace (greater than) and (less than) with their sign/symbol ( Because Youtube donot allow angle brackets in description ) OR You can get this code on github by using github link
Code github Link : https://github.com/ubaidahmadceh/python_projects/blob/main/Secret_Auction.py
code :
import os
bids = {}
bidding_finished = False
def find_highest_bidder(bids):
highest_bid = 0
winner = ""
# bidding_record = {"Angela": 123, "James", "321"}
for bidder in bids:
bid_amount = bids[bidder]
if bid_amount (greater than) highest_bid:
highest_bid = bid_amount
winner = bidder
print(f"The winner is {winner} with a bid of ${highest_bid}")
while not bidding_finished:
name = input("What is your name?: ")
price = int(input("What is your bid?: $"))
bids[name] = price
should_continue = input("Are there any other bidders? Type 'yes or 'no'.\n")
if should_continue == "no":
bidding_finished = True
find_highest_bidder(bids)
elif should_continue == "yes":
os.system('cls')
e auction project python django,online auction project python django,e auction project,e auction project with report ppt,e auction project with source code,online auction project,complete django project,python project with source code,django project with source code