I would use "len" here instead of t.length.