https://github.com/vilasmaciel/bank-kata-calisthenics
Bank Kata following the Object Calisthenics rules
https://github.com/vilasmaciel/bank-kata-calisthenics
coding-dojo kata katas object-calisthenics
Last synced: about 1 month ago
JSON representation
Bank Kata following the Object Calisthenics rules
- Host: GitHub
- URL: https://github.com/vilasmaciel/bank-kata-calisthenics
- Owner: vilasmaciel
- Created: 2018-11-08T12:10:06.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-11-12T14:25:56.000Z (over 6 years ago)
- Last Synced: 2025-03-29T05:11:20.598Z (about 2 months ago)
- Topics: coding-dojo, kata, katas, object-calisthenics
- Language: Java
- Size: 4.88 KB
- Stars: 2
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Bank Kata
Your bank is tired of its mainframe COBOL accounting software and they hired both of you for a greenfield project in your favorite programming language!
Your task is to show them that your TDD-full and your new-age programming language can cope with good ole’ COBOL!
## Requirements
Write a class `Account` that offers the following methods:
* `void deposit(int)`
* `void withdraw(int)`
* `void printStatements()`## The Rules
* One level of indentation per method
* Don’t use the ELSE keyword
* Wrap all primitives and Strings
* First class collections
* One dot per line (Follow de [Demeter Law)](https://en.wikipedia.org/wiki/Law_of_Demeter)
* Don’t abbreviate
* Keep all entities small (50 lines)
* No classes with more than two instance variables
* No getters/setters/properties#### For more information: [Object Calisthenics PDF](http://www.cs.helsinki.fi/u/luontola/tdd-2009/ext/ObjectCalisthenics.pdf)
## Example
An example statement would be:
```bash
Date Amount Balance
24.12.2015 +500 500
23.8.2016 -100 400
```All credits to [Sandro Mancuso](https://github.com/sandromancuso/Bank-kata)