Mike The code t = type(nil) results in an error rather than t being set to "nil". This also occurs with t = type(a) where a has a nil value.