10011002100310041005100610071008100910101011
console.setHistory(history); // load history from history file history.moveToFirstEntry(); while (history.next()) { String entry = history.current(); if (!entry.equals("")) { addToHistory(commandCount, entry); } commandCount++; }