5 kyu

The Bathhouse

18 of 42dfhwze
Description
Loading description...
Algorithms
Simulation
  • Please sign in or sign up to leave a comment.
  • Blind4Basics Avatar

    Not sure if it's an issue or not, but it looks like the sample tests are missing some kind of situations. Ex for me: ['ff', 'ff', 'ff', 'fFF'] -> [(0, 0), (0, 0), (0, 0), (0, 0)]. Up to you to decide if you want to add it or not

  • Blind4Basics Avatar

    The output should reflect the state of the bathhouse after each action (enter or leave).

    AFAICS (I didn't complete the kata yet, but from where I currently stand it looks like this), this is "incorrect"/misleading: enter or leave or a group gets rejected (depends on what one calls "enter", I guess)

    • dfhwze Avatar

      I made it very clear now in the rules:

      If there's insufficient room for the entire group, the whole group is rejected and will not enter the bathhouse. Consequently, they will also not leave, as they never entered in the first place.

      Suggestion marked resolved by dfhwze 4 months ago
    • Blind4Basics Avatar

      errr, no this is kinda the opposite of what I pointed out. You need to remove that part which isn't just misleading, now, it became totally wrong with your last modification:

      The output should reflect the state of the bathhouse after each action ~~(enter or leave)~~.
                                                                             ^^^^^^^^^^^^^^^^^^^^
      
    • dfhwze Avatar

      Really? I'm stating a "rejected" group did not even get to "enter". So what is misleading about (enter or leave)?

    • dfhwze Avatar

      Wait, I no longer remember the specs. Let me check whether rejection is also an action.

    • Blind4Basics Avatar

      since a rejected group now neither entered nor left, according to this sentence no tuple should be added to the output for this event/action, which is in contradiction with each action and the actual implementation.

      edit: yeah, that's it

    • dfhwze Avatar

      Ok got ya, with this test case added, it indeed shows rejected groups also count as action. I was confused, as rejected groups don't get a number assigned to them.

  • Blind4Basics Avatar

    in python, for 3.10+, you don't need to import the types, just use the base functions: tuple[...], list[...], ...

  • RealKenshiro Avatar

    Is the bathhouse gender fluid ? ;)