implemented dictionaryToString