main function: add string buffer to store typing temporary