A few minutes of your real job, every day.
Real work from your role. Read it, write what you would do, and get graded the way a good reviewer would.
Wallet balances going negative under load
Example score: 3of 4
Line 17: def charge_wallet(wallet, amount):
Line 18: _wallet_lock.acquire()
Line 19: balance = wallet.balance
Cited line 20: _wallet_lock.release()
Line 21: if amount > balance:
Example answer: L20 releases the lock before the check and the write, so two threads can both read 100, both pass, and each subtract 80.
- Lock covers only the read, not check and write2 of 2 points
- Shows two threads overdrawing the same balance1 of 1 point
- Holds one lock or uses a conditional UPDATE0 of 1 point
A founder asks for a pause button
Example score: 3of 4
Line 1: Founder: "Three customers asked for a 'pause for a week' button. Can we build it this sprint?"
Line 2: Last month: 2,000 subscribers, 140 cancelled.
Line 3: Reasons given by those 140:
Line 4: Travelling or festival 61
Line 5: Food quality 34
Example answer: 61 of the 140 cancellations are travel or festivals, so people who go away are cancelling. Before we build, I'd call 15 of them.
- States the problem, not the button1 of 1 point
- Uses the cancellation numbers1 of 1 point
- Gives one cheap next step with a measure0 of 1 point
Shorten a tiffin app's sign-up screen
Example score: 3of 4
Line 3: Email address
Line 4: Mobile number (grey placeholder "Mobile", no label)
Line 5: Date of birth
Line 6: Gender
Line 7: Password (rule shown only after an error: 12+ characters and a symbol)
Example answer: Cut email, date of birth and gender: nothing uses them. Keep mobile for SMS and the driver, with a visible label and a number keyboard.
- Removes the fields nothing uses1 of 1 point
- Fixes the mobile field1 of 1 point
- Shows the password rule upfront0 of 1 point
18 roles · 5 to 30 minutes a day · Skills never reset · Free during the beta