Task

Using two Arrays of equal length, create a Hash object
where the elements from one array (the keys) are linked
to the elements of the other (the values)



Related task

   Associative arrays/Creation


 
Module CheckAll {
      Module CheckVectorType {
            Dim Keys$(4), Values(4)
            Keys$(0):= "one","two","three","four"
            Values(0):=1,2,3,4
            Inventory Dict
            For i=0 to 3 {
                  Append Dict, Keys$(i):=Values(i)
            }
            Print Dict("one")+Dict("four")=Dict("two")+Dict("three")  ' true
      }
      Module CheckVectorType1 {
            Dim Keys$(4), Values$(4)
            Keys$(0):= "one","two","three","four"
            Values$(0):="*","**","***","****"
            Inventory Dict
            For i=0 to 3 {
                  Append Dict, Keys$(i):=Values$(i)
            }
            Print Dict$("one")+Dict$("four")=Dict$("two")+Dict$("three")  ' true
      }
      CheckVectorType
      CheckVectorType1
}
CheckAll
 