using more pythonic list access