test constructor added
was rewritten with using "scanner"
details of input changed