alias hashtest {
var %i $iif($1 != $null, $1, 20)
if ($hget(hashtest) != $null) {
hfree hashtest
}
hmake hashtest %i
var %c 1
while (%c <= %i) {
hadd hashtest $+(i,$base(%c,10,10,7)) $+(d,%c)
echo -s added item $+(i,$base(%c,10,10,7)) with data $+(d,%c) to table hashtest.
inc %c
}
var %c 1
while (%c <= %i) {
echo -s reading item $hget(hashtest, %c).item with data $hget(hashtest, %c).data from table hashtest.
inc %c
}
}