Implementing STDIN for calculator expression.