Hello and welcome to the golden programming language course in the previous session, we talked about
map adding, updating and deleting items in this session.
We want to talk about the other maps concept.
Iterate over and map.
We can iterate the map using the range for loop, the value of this loop may vary because the map isn't
an old collection.
The four range loop a statement can be used to fetch the index an element of a map.
Now, go to the school program to illustrate how to iterate the map using four inch loop.
First, create and initialize a map, for the example, in my Mac, Cullen equals map type of index
is each and type of value is strange and initialize for the example, 10 column chain, 20 column it
want
30 column, rather
40 column Alex and then 50 column daily.
Now, it's great, man, using full range lube.
So do the following Go
full sit I.D. for index a name for Value I.D..
Name calling.
He calls Grange.
My radiator, my Mac
and display I.D. a name for each element of Earth.
I the first and the back is legit for a space between idea and name and name person.
As lowercase and like this and said I.D. and name, reformat the code, save the project and execute
the program.
Now we can see the output, we could display and map elements by using four inch loop.
It is important to note that a map is an on ordered set and then the spinning element in it.
The elements may be displayed on order and output in order not to prolong the time of decision.
We will finish it and we will continue the content in the next session.
Goodbye.