![](https://steemitimages.com/640x0/https://cdn.discordapp.com/attachments/404587860872921088/405329216280723458/challenge.png)
For each tutorial we release there will be a relevant challenge where the winner receives 1 STEEM!
Challenge
Today's challenge is a little bit more difficult than usual. Take the code from the tutorial from here and change it to be able to do the following
- Calculate how much your 100% upvote is worth, then upvote the specified post with an upvote that is equal to the received SBD (so if it's less, you should refund the difference)!
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
How To Create Your Own Upvote Bot 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!
Code: https://gist.github.com/maxwellgerber/f6b8cfd861228e28f8a57f8887e3a0e8
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Again on point! Just about to go over the code from the challenge from yesterday and you have already submitted another ;)
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Just tested it and there are some tiny errors, but if you fix them, then it works as specified! Go, go, go, if you are quick you can still win!
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Cleaned and updated!
There was one pretty big error with how I was calculating voting power. The voting power param set on the account object is your VP at the last time you voted. So you need to do some math with the last vote time to figure out your current real voting power.
I actually had to find this one by going through the source code for steemnow
![](https://steemitimages.com/DQmZF75n9KMfq6sjwQ385bvk4DZQtezCW3kvBBs2f5A1kkt/image.png)
Other than that it was just import errors and the like :P
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
O wow, I didn't know that about voting power! I just sent you the STEEM, congratulations!
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
😇
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit