Added code

First usable implementation