copy challenge implemented
some bug fixing