Add reference links to hash functions in Toteutusdokumentti and fix time complexity