Well... you can imagine it as 2D table, like MS excel ... with rolls and columns. You can store Data in it and call that Data by roll and column.
One of the biggest pros is that you can use Unit Handle as a parameter so you wont need indexing to access it.
Another big pro is that you can store ANY Data in it.
Here is an example:
We have a variable of type integer with an array. It will look like Integer[Array]
You can do Integer[Array] = SomeInteger, if you try to do Integer[Array] = SomeReal you will get an error (This is impossible in GUI but in JASS you can write anything)
With a hashtable you got Cell[Roll][Column] = Data
You can do Cell[1][1] = SomeInteger, Cell[2][1] = SomeUnit, Cell[3][1] = SomeAbility
Another pro is thet you can pass a unit Handle as Roll/Column, which will corespont to only 1 Roll/Column
So if you use rolls for CasterUnit and colums for SummonedUnit
And the storage for summons will actualy start from 2 because we want to keep track of the number of summons.
You will have :
Actions
Spawn SummonedUnit
Set NumberOfSummons = ( Get Cell from hashtable [Handle of Caster Unit] [1] ) + 1
Cell[Handle of Caster Unit][NumberOfSummons] = Last created unit
You will need a trigger to get rid of dead summons which are taking space
You will need another trigger
Event
Unit - Dies
Condition
Unit type of triggering unit == Summoner
Action
For loop LoopInt from 2 to ( Get Cell from Hashtable [Handle of Triggering unit] [1])
Kill Unit (Get Cell from hashtable [Handle of Triggering unit] [LoopInt])
{Notice that counting NumberOfMonsters starts from 2, this is because Cell Column is reserved for the actual integer}
Note: The code does not look like this neither in GUI or JASS, it just helps to explain as I assume you are familiar with Arrayed Variables because you use an indexing system...
Note: I am not sure if counting in hashtables starts from 1 instead of 0...