change to scanner to function

change to scanner to function