Welcome back.
Let's start building our application.
Here I'll create a new composable function named as Lazycolumn with sticky header.
And inside it I'll create val grouped items equals to map of fruits to list of apple, banana, cherry,
mango, grapes, watermelon.
Then we need to create vegetables to list of carrot.
Lettuce.
Tomato.
Onion.
Potato.
Eggplant.
This code in Kotlin creates a map named Group items that maps categories of items to the list of items
within those categories.
Map of this function creates a map where each entry consists of a key and a value.
Fruits and vegetables are the keys in the map.
List of and.
This list of are the values associated with the keys, fruits and vegetables respectively.
So again, these are the keys fruits and vegetables.
And these are the values for these keys respectively.
And by the way in order to access the fruits we can specify for example variable my fruits equals to
grouped items.
And here we specify the key.
So the output of this variable will be apple.
Banana.
Cherry.
Mango.
Grapes.
Watermelon.
All items in this key.
This is how we create the map which will be the data source for our application.
Later on, we'll edit this map and replace it with custom objects