Back to Freecodecamp

Class vs. Static Methods

curriculum/challenges/english/blocks/methods-and-inheritance/class-vs-static-methods-video.md

latest551 B
Original Source

--description--

In this video, you will learn the difference between class and static methods.

--questions--

--text--

What is a class method?

--answers--

A method that only works with global variables and is unrelated to the class or its instances.


A method that can only be called on an instance of a class and cannot access class-level attributes.


A method that automatically runs when an object is deleted.


A method that is bound to the class itself, rather than an instance of the class.

--video-solution--

4