Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re^3: Perl 6, Object Orientation and Melting Brains

by Mugatu (Monk)
on Mar 28, 2005 at 18:57 UTC ( #442906=note: print w/replies, xml ) Need Help??


in reply to Re^2: Perl 6, Object Orientation and Melting Brains
in thread Perl 6, Object Orientation and Melting Brains

The main difference between object oriented programming and procedural programming can be boiled down to where the data is stored. If the data is stored by the main program, and passed in to the functions, that's usually procedural code. If the data is stored by the functions themselves, and the main code just asks the functions to do things, that is usually object oriented.

As dragonchild said, this moves the responsibility of that data away from the person writing the main code, and onto the the person writing the object itself. Even if that person is the same person, the two different areas of code can be written in different frames of mind. I think it helps create clean separation of concerns. Also, it's often just darn convenient. Passing the same data structures around constantly can be a real pain. Objects are a solution to that problem.

  • Comment on Re^3: Perl 6, Object Orientation and Melting Brains

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://442906]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (3)
As of 2022-01-21 06:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:












    Results (57 votes). Check out past polls.

    Notices?