Adding solution for problem 55 in c.