added code to persist assignments and display index