modified randominputtext.cpp file