Creating and traversing arrays