Re-format classes list into table with class number