38. Collections Namedtuple: Hackerrank | Python Solution Explained

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

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

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

    I want to thank you for all of your great videos. I am teaching a basic Python class in my local community and your videos are very useful. Great Job.

    • @AmirCharkhi
      @AmirCharkhi  2 месяца назад +1

      This made my day! Thank you for your support and encouragement. Appreciate what you do for your community and please let me know if I can be of any help. More than happy to lend a hand🙂

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

    MARKS, CLASS, NAME, ID = input().split()
    I did not know you could do this. It seems it's automatically assigning a variable to each item in the list that split() returns. Very cool.

  • @MohammedAhmed-y9r
    @MohammedAhmed-y9r 9 месяцев назад +2

    Thanks , you're the best !!

    • @AmirCharkhi
      @AmirCharkhi  9 месяцев назад

      Thanks for the nice words, happy to help🙂

  • @ashharrayan1571
    @ashharrayan1571 7 месяцев назад +4

    Could you please explain ...when it takes input how does it stays in the order ???? Very confusing?

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

    Great, video!

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

      Glad you enjoyed it🙂

  • @karasa1
    @karasa1 Месяц назад

    Could the container be created outside the loop?

  • @tazinga8990
    @tazinga8990 7 месяцев назад +3

    Could you explain the part where you took input off all the fields in the for loop...how does it stay in the order corresponding to the user's order??

    • @g4uravrawat663
      @g4uravrawat663 3 месяца назад +1

      have you find the solution to it

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

    The order of the column names changes in the input. For example, test case 0 has:
    ID MARKS NAME CLASS
    But test case 1 has:
    MARKS CLASS NAME ID
    How does the code handle that?