to have fun coding like you always wanted to Make tests important in your life Leaving you comfort zone Knowledge transfer – while listening to others Your code is not your baby!
tools Practice solving interesting problems Be part of the community Not only working, but well-crafted software http://manifesto.softwarecraftsmanship.org/
code only) Person B only tries to get the tests to pass (production code only) Both persons refactor when appropriate Navigator-Pilot Person A designs algorithms, tests (usually on paper), performs on-the-fly code review Person B writes the actual code Especially suitable when the pair is uneven in coding ability But, the more able coder can assume any of the roles! Regular Ping-pong Person A only writes ~ 4 lines of code Person B only writes ~ 4 lines of code Repeat…Refactor
Horton Conway in 1970 A cellular automaton Evolution depends only on initial state, no user input required afterwards Our today’s an anchor problem Well defined Simple, yet interesting Easy to solve in small scales, yet difficult for large ones Many implementations exist, vastly more are possible
of square cells, each of which is in one of two possible states, alive or dead. Every cell interacts with its eight neighbors, which are the cells that are horizontally, vertically, or diagonally adjacent. Transitions are discrete – occur in ticks
Any live cell with fewer than two live neighbors dies as if caused by under-population Any live cell with two or three live neighbors lives on to the next generation. Any live cell with more than three live neighbors dies as if by over-population Any dead cell with exactly three live neighbors becomes a live cell as if by reproduction.
as if caused by under-population Any live cell with two or three live neighbors lives on to the next generation. Any live cell with more than three live neighbors dies: as if by over-population Any dead cell with exactly three live neighbors becomes a live cell: as if by reproduction
your pair partner According to your language of choice Free-Style Just try to solve the problem as you see fit Get to know the rules of Life What about the infinity problem? How to name things? Don’t have to write tests!
make you understand the problem more Tests make for great acceptance criteria Tests will save your time – no only in the end Fast code verification: no need to run whole module/product to debug Tests will make you a braver coder “TDD is not dead or alive. TDD is subject to tradeoffs, including risk of API changes, skill of practitioner and existing design” Kent Beck.
lifecycle mood time Day 1: I love designing and coding stuff Day 2: Still good, posting for review Day 3-4: I have to make it ‘work’ until Demo! Damn! Unit tests… L
GOL algorithm so that it is encapsulated in a docker container Start, next iteration as a REST API call Ideally, start a microservice for each living cell (and dispose of it as it dies)