February
15th,
2016
Tuples
A tuple is a way to organize data. It’s a way to group togeter many terms when you known how many there are.
{Element1, Element2, ..., ElementN}
通常使用tagged tuple
, 例如:
Temperature = {celsius, 23.213}.
Point = {point, {1, 2}}.
取值
{celsius, T} = Temperature.
{point, {X, _}} = Point.