Associative array/Merging: Difference between revisions

Content added Content deleted
Line 740: Line 740:
let t2 = {"price": "15.25", "color": "red", "year": "1974"}.toTable
let t2 = {"price": "15.25", "color": "red", "year": "1974"}.toTable


var t3 = t1 # Does a copy.
var t3 = t1 # Makes a copy.
for key, value in t2.pairs:
for key, value in t2.pairs:
t3[key] = value
t3[key] = value