Editor

Python simulation problems

Follow the rules step by step until something happens: simulation problems in Python, with tests.

Beginner

  1. 46. Robot on a GridFollow the commands and find out where the little robot ends up40 XP8 min
  2. 225. Rock, Paper, Scissors TallyA whole afternoon of hand games: who won more rounds?30 XP6 min
  3. 232. Traffic LightGreen, yellow or red: what colour will the light show when you get there?30 XP6 min

Intermediate

  1. 84. Spiral Walk Through a MatrixWalk around the edges and work your way into the middle70 XP14 min
  2. 99. Game of Life: One StepCells are born, survive or die, all at the same instant80 XP15 min
  3. 281. Langton's AntOne tiny ant, two simple rules, and a surprise after ten thousand steps65 XP14 min
  4. 313. Bowling ScorecardStrikes, spares and the tricky tenth frame75 XP18 min
  5. 318. Parking Lot With a Waiting LineThe lot is full and the line is long: which cars have to drive away?75 XP16 min

Advanced

  1. 132. What Day of the Week?Name the weekday of any date in ten thousand years of calendar120 XP25 min
  2. 361. Snake GameEat, grow, and never bite your own tail125 XP28 min
  3. 379. War, the Card GameTwo decks, no choices to make: who ends up holding every card?135 XP30 min
  4. 393. Slide and MergeSlide the tiles, merge the twins, chase the big number140 XP30 min

Expert

  1. 190. The Office ElevatorOne elevator, a crowd of passengers: when does each one arrive?240 XP55 min
  2. 436. Sandpile AvalanchesPour on the sand and let the avalanches run until everything settles200 XP40 min
  3. 444. Falling BlocksDrop the pieces, clear the full rows: how tall is the pile at the end?220 XP50 min
  4. 451. Bank TellersSome customers jump the line, some give up: how long does each one wait?230 XP50 min
  5. 488. Life on an Endless BoardWhere will this colony of cells be a trillion generations from now?260 XP55 min

Other topics

Or see every challenge, with study plans, today's challenge and duels.