-3

What's the difference between a method and a function in oop ?

  • 1
    A method is a function that is part of a class. It gets called through an object, as in `obj.method()`, as opposed to a non-method function, which is called `func(a,b,c)`. – Tim Roberts Apr 16 '23 at 06:23

1 Answers1

0

A method is a function of a class.

KSHMR
  • 741
  • 1
  • 9
  • 24