Daily Steem-Python Challenge #12, Win 1 Steem!

in #programming7 years ago (edited)

For each tutorial we release there will be a relevant challenge where the winner receives 1 STEEM!

Challenge

Take the code from the tutorial from here and change it to be able to do the following

  1. For each vote that was done before 30 minutes calculate the curation reward they would've received if they voted after 30 minutes. Compare this to their actual curation reward (print both) and show how much more the author got in rewards because of them voting before 30 minutes.

That's it! Good luck to everyone participating!

Deadline

The prize money will be rewarded to the person that solves the problem first. If there is no solution within 7 days after this post has been submitted the prize pool expires.

Relevant Tutorial

Part 12: How To Estimate Curation Rewards Using Steem-Python


If you have questions about the tutorial or the challenge then don't hesitate to comment below or contact us on Discord!

Sort:  

Maybe something like this? https://pastebin.com/HsnX0H6Y

I can't run this without getting TypeError: must be str, not float.

Oh, my fault. Sorry. https://pastebin.com/5f5A2fwi

Seems like the correct solution, congratulations!

Nice, thank you :)

What happened to the weekly challenges, too? 😜

Initially the idea was to do weekly challenges, but we quickly realised that is was better to do a challenge for each tutorial. So there are no weekly challenges anymore. I will change the text