Add functions to flatten list and display only 1 level of list