Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $city = [ "Dhaka" , "Dinajpur" , "Rangpur"];
- for($i=0; $i<count($city); $i++){ // count($city) will count the elements under the city array condition look like (0<3)
- echo "{$city[$i]}<br />\n"; //when $i == 0 it will be act like $city[0], when $i == 1 it will be act like $city[1]
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement