Classes (Part 3) Accessor and Mutator methods

Поделиться
HTML-код
  • Опубликовано: 18 сен 2024
  • Writing more methods

Комментарии • 14

  • @IloveBaoTran
    @IloveBaoTran Год назад +1

    can't believe this is 13 years ago, you're legend

  • @timebrahimy3917
    @timebrahimy3917 8 лет назад +3

    Thanks David for a very clear and well presented video tutorial on python classes.Tim

  • @billionairemotivationseven8six
    @billionairemotivationseven8six 5 лет назад +1

    where are new videos?

  • @parthasarathibarman9862
    @parthasarathibarman9862 3 года назад +1

    Watching in 2021 :')

  • @papakiparii352
    @papakiparii352 6 лет назад +1

    please show accessor and mutator method for emplyee class

  • @zwescientist
    @zwescientist 10 лет назад +1

    When I create an object myr = Rectangle(10,5). It returns the following error
    Traceback (most recent call last):
    File "", line 1, in
    myr = Rectangle(10,5)
    TypeError: object() takes no parameters

    • @chirayu8210
      @chirayu8210 3 года назад +1

      it means there are no parameters in constructor
      so do it like this
      def__init__(self,width=0,height=0):
      it will work i was also having the same error but by doing it like this it solved the problem

    • @zwescientist
      @zwescientist 3 года назад +2

      @@chirayu8210 I was still a noob. Now I am laughing at my comment six years later, lol

  • @gigigaou
    @gigigaou 4 года назад +2

    Well rip

  • @user-tw9il5br2x
    @user-tw9il5br2x 6 месяцев назад

    Watching 2024 : )

  • @vkalishnikov
    @vkalishnikov 12 лет назад

    how bout java..?