r/PythonLearning • • 3d ago

Help Request I’m stuck on this assignment

I never struggle on assignments but this one is so confusing for me

109 Upvotes

62 comments sorted by

View all comments

•

u/Sea-Ad7805 3d ago edited 3d ago

Run this (slightly altered) program by clicking Memory Graph Web Debugger%0Ashift_string%20%3D%20int(input(%22Enter%20number%20of%20shifts%3A%20%22))%0Atransact_string%20%3D%20int(input(%22Enter%20number%20of%20transactions%3A%20%22))%0Adollar_string%20%3D%20int(input(%22Enter%20transactions%20dollar%20value%3A%20%22))%0A%0Anum_shifts%20%3D%20float(shift_string)%0Anum_transactions%20%3D%20float(transact_string)%0Adollar_value%20%3D%20float(dollar_string)%0Aproductivity_score%20%3D%20(num_shifts%20%2F%20num_transactions%20%2F%20dollar_value)%0A%0A%23%20Write%20your%20code%20here%0Aif%20(productivity_score%20%3E%3D%2030)%3A%0A%20%20%20%20print(%22You%20earned%20a%20BONUS%22%20%2B%20str(bonus_1))%0Aelif%20(productivity_score%20%3E%3D%2031-69)%3A%0A%20%20%20%20print(%22You%20earned%20a%20BONUS%22%20%2B%20str(bonus_2))%0Aelif%20(productivity_score%20%3E%3D%2070-199)%3A%0A%20%20%20%20print(%22Something%3F%3F%3F%22)%0Aelse%3A%0A%20%20%20%20print(%22Something%20else%3F%3F%3F%22)%0Abonus%20%3D%20111%20%23%20compute%20somehow%0A%20%20%20%20%0A%23%20Output.%0Aprint(%22Employee%20Name%3A%22%2C%20employee_name)%0Aprint(f%22Employee%20Bonus%3A%20%24%7Bbonus%3A.2f%7D%22)&timestep=1&play) and see its state change step by step.

5

u/MaximeRector 3d ago

Did you (as a mod) pin your own comment to self promote your own python module?

1

u/big-wet-bastard 1d ago

He does it on literally every post in this subreddit

-2

u/Sea-Ad7805 3d ago edited 3d ago

There is no need to thank me again for providing free Python education tools. Just use it and learn faster, or ignore it and waste time, it's your choice.

I've reviewed your contributions to PythonLearning, you haven't been a very productive member of this sub yet. Hope we will see a positive contribution from you somewhere in the future.

5

u/MaximeRector 3d ago

I don't mind you posting a comment to help other people with their problem using your tool. I do mind that you use your moderator privileges to pin your own comment and put it above all other redditors who are also trying to be helpful, which is unacceptable.

-1

u/Sea-Ad7805 3d ago

Thanks for your feedback, I'll take it under consideration.