for文は何気に書くのが面倒なので、foreachを使うと楽。

foreach (range(1, 10) as $index) {
///
}
Sign up for free and join this conversation.
Sign Up
If you already have a Qiita account log in.