A simple test follows:
${message}
Now iterate over a list:
<#foreach item in list>${item}
#foreach>Now iterate again:
<#list list as item>${item_index}. ${item}
#list>Iterate over a list in a hash:
<#list hash.key as item>${item}
#list> <#foreach item in hash.key>${item}
#foreach> <#foreach item in hash[ "key" ]>${item}
#foreach> <#list hash["key"] as item>${item}
#list>Now test the list and foreach keywords...
<#list hash2["value"].key as key>${key}
#list> <#foreach az in hash2.value.key>${az}
#foreach>