Write basic for loop