Add indices to brackets to support Python <2.7