assignment completed

added code to both functions, it works