remove hard coded zero in prefix(). add test for inheritance