Update hello.cpp

add sub method