Open tnuanchuay opened 6 years ago
Reference (sorry, thai language video) https://www.youtube.com/watch?v=y9I4Vsj6G0g
Thats still fuzzy on my mind. Can u help spell down the rules. Likely we would pick the one that withstand the most increasing load but how do we resolve when correctness is in consideration.
Can u open PR with RULES.md file and spell out some of these so we can all review ? Thx
I've read Rule page in Google Slide after create this issue and it's very clear, actually. I thought we choose winner from they can pass the load testing so we may have many winners.
btw, I'll write RULES.md
I think we should put more weight on the correctness. Because even if the correctness is 99 percent, but if 2 users got the same seat, that doesn't sound good.
Actually now that i think about it. Maybe we should make the rules easier to check
Let's remove concept of rounds. only limited number of seats (say 10k). But we decide who wins by those who can sell all tickets correctly, and use the least amount of time.
getAvailableTickets()
to get up to 10 remaining seatsbook(seat)
-> wait 1-2 seconds -> confirm(seat)
(if seat is not confirmed within 5 seconds. it will be back to the poolThe winner needs to do these
@mahasak if this LGTU i'll merge
Please add the agreed rules to README.md and change reference implemenatation to match (Remove rounds)
@varokas LGTM, let @tspn add details to README.md
Also, getAvailableTickets() returns count of tickets booked but not confirmed
From Thai about persistence. we will check 2 times
@varokas It shouldn't call getAvailableTickets() if it returns only tickets booked but not confirmed I will name it getUnconfirmed(). Is it ok?
I think getAvailableTickets()
should make sense. It means get all tickets that is available to book.
How do we know who will win this competition? just only they pass the test and get correct booking result? response time/capacity should be minor factor?