Output in html-table. Processing by using stack (Less optimization)