inheritance exercises