merged
now tests work with puzzle of size n