Finished implementation of PS1