Modified existing algorithms and added put_key