avoid weird array accessing method