add inherit.cpp