add function "child" that returns the first child of an object