srm 622 div2 500.cpp