eli5 what is object oriented programming? honestly eli5

1.53K views

eli5 what is object oriented programming? honestly eli5

In: Technology

9 Answers

Anonymous 0 Comments

OO organises code into classes, properties, and methods. The simplest way to explain is with examples:.

Class: The definition of a Reddit account.

As part of my class, I need to define:

Properties: The information I need to store against a RedditAccount. I need a user name and an email address.

Methods: What I can do with a RedditAccount. I can create a post, reply to a post, or edit a post.

So what’s an object? It’s what I get when I actually use my class for something. Also referred to as an “instance”. AlterEdward is my RAccount object. It’s had all its properties populated, which means I can use its methods to make posts.

You are viewing 1 out of 9 answers, click here to view all answers.