Ad
  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    (approved by ..)

  • Custom User Avatar

    No offense at all, don't worry.

    But your answer for that case doesn't match the task. The goal is to give the number of buses needed to carry people, and if there is a restriction on the number of adults vs the number of kids, there is no restriction on the number of adults "alone". so 0 cannot be a valid answer here.

    Side note: that expected output is coming from the author's solution, not mine.

  • Default User Avatar

    Hello Blind4Basics et al,

    My contention is that since there are no 'kids' to be chaperoned to the camp an alternative answer might be zero.

    I apologise if I have caused you any offense. That was not my intention.

    I'm merely putting forward a different answer.

    I hope that makes my position clear.

  • Custom User Avatar

    I'm sorry, I don't understand your message.

    I shouldn't argue about what? I'm not arguing at all, actually... => ?

    And in that second example, one actually need 18 buses to "move" the adults. => ??

  • Default User Avatar

    Hello Blind4Basics et al,

    Could it not be argued that since in your second example below where kids = 0 the answer could equally be zero... as no kids are going to camp?

    Just a thought...

  • Custom User Avatar
  • Custom User Avatar

    Added in this Fork

  • Custom User Avatar

    Additional fixed tests:

    buses(0, 0, 0) -> 0
    buses(0, 1, 0) -> 0
    buses(0, 2, 0) -> 0
    buses(0, 34, 1) -> 34
    buses(5, 10, 2) -> 0
    buses(0, 9, 2) -> 5
    
  • Custom User Avatar

    .

  • Custom User Avatar

    thanks a lot, fixed it

  • Custom User Avatar

    Approved by someone, thx

  • Custom User Avatar
  • Custom User Avatar

    Hi,

    those should be added to the fixed and example tests in all languages:

    buses(17, 1, 39), 0
    buses(0, 35, 2), 18
    buses(21, 3, 23), 2
    

    Cheers

  • Custom User Avatar

    fixed it

  • Loading more items...