+ 2

Object oriebted programming

I'm basically code averse guy spent years of job out of coding. But Python excites me and induces me to stretch a little further. I have come all the way till object oriented programming in SoloLearn. Making a progress in OOPs is now a big challenge for me. I need someone help to define anatomy of oops and complete my course without any lag. Your small clue will push me to succeed. Thanks, Bharathi Kannan

29th Nov 2019, 7:47 PM
Bharathi Kannan Kumarasamy
Bharathi Kannan Kumarasamy - avatar
4 odpowiedzi
+ 16
In object-oriented programs data is represented by objects. Objects have two sections, fields (instance variables) and methods. Fields tell you what an object is. Methods tell you what an object does. These fields and methods are closely tied to the object's real world characteristics and behavior. When a program is run messages are passed back and forth between objects. When an object receives a message it responds accordingly as defined by its methods.
29th Nov 2019, 8:58 PM
Danijel Ivanović
Danijel Ivanović - avatar
+ 8
Every object you know in real life can be described as an OOP object that holds information in its properties and can perform tasks by its methods. Simple things like a deck of cards are an object. The deck knows properties such as the name & order of the cards it holds or which cards are missing. It can perform methods like shuffling the cards or dealing out a few of them. Your wallet contains things and you add money earned or removed from your bank to it or spend money from it.
29th Nov 2019, 8:24 PM
John Wells
John Wells - avatar
0
you said you spent years of job out of coding but you didn't even understand OOP? doubt.
30th Nov 2019, 5:02 AM
Shen Bapiro
Shen Bapiro - avatar
- 1
I meant, I'm not a coder by nature of work. Significant work experience is on infrastructure management and I moved on to Cloud. Now everything on cloud is being automated.. I still write shell scripts for day in day out automation. But not having professional coder experience!!! Python broke my hesitation on coding, yet I feel that I need some help to completely understand OOP.
30th Nov 2019, 5:13 AM
Bharathi Kannan Kumarasamy
Bharathi Kannan Kumarasamy - avatar