Ask your own question, for FREE!
Computer Science 14 Online
CriminalilticFool:

Computer Science project code. Used python. I'll add a couple screenshots to this. item_name1 = input("Enter food item name:\n") item_price1 = float(input("Enter item price:\n")) item_quantity1 = int(input("Enter item quantity:\n")) total_cost1 = print_receipt_item(item_name1, item_price1, item_quantity1) item_name2 = input("\nEnter second food item name:\n") item_price2 = float(input("Enter item price:\n")) item_quantity2 = int(input("Enter item quantity:\n")) total_cost2 = print_receipt_item(item_name2, item_price2, item_quantity2) total_cost = total_cost1 + total_cost2 print(f"\nTotal cost: $ {total_cost:.1f}") gratuity = 0.15 * total_cost grand_total = total_cost + gratuity print(f"15% gratuity: $ {gratuity:.1f}") print(f"Total with tip: $ {grand_total:.1f}")

CriminalilticFool:

1 attachment
Breathless:

what about it

CriminalilticFool:

Asking if you think it would have this output.

1 attachment
LizzyLovely:

Cool cool

LizzyLovely:

@breathless wrote:
what about it
Not him answering literally everyone's questions so he can get to lvl 50 πŸ™πŸ₯Έ

Bones:

@lizzylovely wrote:
@breathless wrote:
what about it
Not him answering literally everyone's questions so he can get to lvl 50 πŸ™πŸ₯Έ
πŸ˜‚

Breathless:

HOW DID U KNOW-

LizzyLovely:

@breathless wrote:
HOW DID U KNOW-
Big brain πŸ₯Έβ˜

Bones:

@breathless wrote:
HOW DID U KNOW-
Isn't that what everyone wants?

alphaXtiger:

@breathless wrote:
HOW DID U KNOW-
It's obvious πŸ’€

Breathless:

Lol-

Breathless:

mb g's

alphaXtiger:

Lol

Breathless:

anyways

Breathless:

Food

Bones:

Lol

Aratox:

Just so you know, this isn't how Python would be used in real life - this would require `import`ing seveal modules to the lib, and then you'd still have to construct this code. It seems that whatever you're running the code on is a simplified version of a code editor (probably utilizing Vanilla Python). So, as long as I don't have access to this code editor, then I can't answer your question.

CriminalilticFool:

Thanks Aratox! This was just something I put out there because I wanted to see people's thoughts on it. But I really do like the input you gave!

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!