Implemented basically everthing. Known bugs: password collisions are not handled, and the counter doesnt work.
Fixed count error