IB Computer Science - Topic 4 - Part 2 (Mod and Div, Validation, Methods)

Поделиться
HTML-код
  • Опубликовано: 12 янв 2025

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

  • @valeriacorona7339
    @valeriacorona7339 Год назад +9

    Your series is very helpful to al cs students, you have no idea. Please if you can practice some more SL past papers questions. Thank you so much 🙏🙏🙏🙏

    • @TheCSClassroom
      @TheCSClassroom  Год назад

      I'll see what I can do. I'm still working on Option D and rapidly running out of time before the exams 😭

  • @DaniswaraPradana
    @DaniswaraPradana Год назад +3

    Im very glad I found your channel just right before my semester examinations, thank you so much🙏

  • @rockymoose1235
    @rockymoose1235 8 месяцев назад +1

    youre the best, im studying for my first mocks and these videos are great!

  • @bobabooks
    @bobabooks 2 месяца назад

    once again, thank you so much!!! i've been using your videos to prepare for mocks, and the pseudocode video are amazing ☺

    • @TheCSClassroom
      @TheCSClassroom  2 месяца назад

      Glad they're helping! Good luck with the mocks!

  • @taanishqverma5253
    @taanishqverma5253 Год назад +3

    5:52 it should be 5 right?

    • @TheCSClassroom
      @TheCSClassroom  Год назад +2

      Yes, I actually linked a different, correct Mod and Dic example in the comments - this one was kind of a mess.

  • @RobertNillson
    @RobertNillson 11 месяцев назад

    I have a question why do you write name(30) and Weight(30) and Height(30) in 30:56 is it supposed to be 29

    • @TheCSClassroom
      @TheCSClassroom  11 месяцев назад

      The 30 refers to the number of elements in the array, not the index of the last element in the array.

  • @pyneapplejohnson5460
    @pyneapplejohnson5460 8 месяцев назад

    Thank you Big Dog - I want to see them practice problems

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

    please do more ib examples for HL topics

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

      I made a 3-part series on Topic 5: ruclips.net/video/M5QYynjOaRU/видео.html

  • @TheClashMaster
    @TheClashMaster 8 месяцев назад +1

    Hey, very random question but what keyboard do you use? It sounds so nice in your examples haha

    • @TheCSClassroom
      @TheCSClassroom  8 месяцев назад

      Haha, I just use my MacBook keyboard.

    • @TheClashMaster
      @TheClashMaster 8 месяцев назад

      @@TheCSClassroom oh makes sense, thank you for the videos!

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

    could you please explain how to solve trace tables as well?

  • @arcosakirkhan7267
    @arcosakirkhan7267 Год назад

    Will this solution work for the Mod & Div Practice Question? I tried it myself first but the approaches we have taken are different. Kindly let me know.
    Input CENTS
    CENTS_F = 0
    QUARTER = 0
    DIME = 0
    NICKEL = 0
    PENNY = 0
    Loop while CENTS > 99 then
    Output (‘Value too big, has to be at a maximum of 99 cents’)
    Input CENTS
    Endloop
    Loop while CENTS_F != 0
    if
    Q = CENTS div 25
    Q = QUARTER
    CENTS_F = CENTS - (QUARTER * 25)
    Else if
    D = CENTS_F div 10
    D = DIME
    CENTS_F = CENTS_F - (DIME * 10)
    Else if
    N = CENTS_F div 5
    N = NICKEL
    CENTS_F = CENTS_F - (NICKEL * 5)
    Else if
    P = CENTS_F div 1
    P = PENNY
    CENTS_F = CENTS_F - (PENNY * 1)
    Endif
    End loop

    Output (QUARTER ‘Quarters’, DIME ‘Dime’, NICKEL ‘Nickel’, PENNY ‘Penny’)

  • @dhwanimehta3680
    @dhwanimehta3680 Год назад

    why is 3 mod 28 = 3

    • @TheCSClassroom
      @TheCSClassroom  Год назад

      When you use mod, you're finding the remainder after division, but that can't happen unless the first number is bigger than the second. Until that point, the first number will be your answer.

  • @titasmotekaitis
    @titasmotekaitis Год назад +2

    I'm pretty sure you made mistakes in the cents example as you calculated the remainder wrong. It should have been remainder = remainder mod 10, and so on... otherwise great video man😄

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

      Good catch! I hadn't noticed that. Well, hopefully it at least illustrated how mod and div worked, which was the main objective. I'll publish a correction in the description.

  • @TheCSClassroom
    @TheCSClassroom  Год назад +2

    I make mistakes too:
    LINK TO CORRECT MOD AND DIV EXERCISE CODE:
    docs.google.com/document/d/14WVgRFiqKdUzz13FvukFh1GzUWitr26CZUThyKBWnnE/edit?usp=sharing