Skip to main content

All Questions

1vote
3answers
143views

A Class that creates a unit of Stock or a collection of Stocks

I have a dataclass of a single class object 'AStock' as such: ...
mrkgoh's user avatar
8votes
3answers
3kviews

Calculate evapotranspiration

I am trying to create a code for the Basic evapotranspiration equation by Hargreaves. I have attached a screenshot of the equation to be replicated. I want to create a class wherein I can input data ...
jeronimo dcosta's user avatar
3votes
1answer
45views

Weekly Dose tracker with time and dose mean

Function: Outputs daily and weekly dose totals with means for time between doses and dose amount. Code: ...
Nickotine's user avatar
2votes
1answer
208views

Extending the inclusion-exclusion principle to general objects

Introduction I have implemented a generalization to the inclusion-exclusion principle, which extends the principle from sets to more general objects. In short the principle calculates the left by ...
N3buchadnezzar's user avatar
3votes
2answers
294views

Temperature Converter: °C to K

What it does Converts melting point and boiling point from degrees celsius to kelvin These are in a dict which is in a tuple as no changes should be made to it No user input Purpose Learning ...
Nickotine's user avatar
3votes
1answer
217views

Game in Python3 using OOP

So iam making a game using OOP in python however is this the best practise when defining your objects? are you meant to define them all at the end of the script like I've done, or are you meant to ...
Mj _'s user avatar
2votes
1answer
5kviews

Python code for simple Vending Machine simulation implementing OOP principles

I am recently learning OOP concepts and thought that implementing a simple workflow simulating a vending machine would help me put what I've learnt into practice. I am open to criticisms and feedback, ...
jtsw1990's user avatar
7votes
2answers
2kviews

Cleanly passing in a large number of mutable parameters through a python class

I want to create two classes, one for attributes and one for functional behaviors. The point of the attributes class was to hold all of the attributes along with property methods (setters/getters), ...
Simply Beautiful Art's user avatar
14votes
2answers
2kviews

Blackjack with card representation visuals

To try and practice OOP, I've heard making a blackjack game can be really helpful; which it has been. I don't know how 'advanced' an implementation this is; but it has all the standard features, like ...
Zach Sonnenblick's user avatar

close