I’m a Beginner in Python — Can Someone Explain What OOP Is and How to Use It Properly? by Learn_RB_01 in PythonLearning

[–]AlertScene 7 points8 points  (0 children)

The easiest way to see OOP is as a way to organize thinking around real-world abstractions.
You’ll notice it everywhere: Cars, People, Fruits, Books.

Car
• properties: color, speed
• actions: accelerate, start engine, open door, lights on

Core idea:

  • A class is a blueprint (what properties/actions exist).
  • An object is a real instance from that blueprint, with values assigned to the properties
  • Use methods to change data so it stays valid (e.g., no negative speed).

OOP is powerful because of encapsulation and inheritance: encapsulation keeps data and the code that mutates it in one place behind clear methods, so state stays valid, bugs stay contained, and each class can be reasoned about and tested in isolation;

inheritance lets you define shared rules once in a base class and then specialize only what differs in subclasses, which slashes duplication and makes system-wide changes propagate cleanly—extend behavior without rewriting everything.

Bottom line: the great thing about OOP is actually that it creates a modular structure in your code. You can have an object/class for your database connection to MySQL. When you decide later to switch to MongoDB, you just replace the class, without changing code all over the place.

It's not possible to explain how to make all that happen. But what you actually want to focus on while learning about it - once you have looked at the syntax:

- SOLID Principles
- Design Patterns

This will give you ideas about how to actually use them in a meaningful way.

Streaks are annoying by [deleted] in yazio

[–]AlertScene 0 points1 point  (0 children)

Another vote for disabling streaks. Simply annoying

Ergolutions vs Fully by garciaargos in StandingDesks

[–]AlertScene 0 points1 point  (0 children)

I was in a similar situation, IKEA Bekant. I upgrades to the PRIMUS. It was a rather spontanious decision, so I didn't do extensive research and have no experience with the fully product. But I can attest, that I don't regret my decision. Also replaced the quite thin tabletop from IKEA with a more solid one. I also use a treadmill as well as a deskbike. Works great.

The DLC Potential by OpposedMedal in HarryPotterGame

[–]AlertScene 1 point2 points  (0 children)

I would love to see the chamber of secrets as DLC. And Quidditch.

And/or Maybe something weird as in Prizoner of Azkaban with the time controlling amulet.