update TreeInputConsole code