0

How to output like this in hp

2,2,3,3,4,4

18th Mar 2020, 6:38 AM
Putra Cipuik
4 Respostas
+ 3
Umm, isn't it pretty simple if you completed php looping course from Sololearn? Make a counter variable that starts from 2 as you want to start printing from 2. $counter = 2; //now we will run a while loop here, you can use for loop if you want. //Condition is less than 5 because you want to print it till 4 only. while($counter < 5){ echo $counter.",".$counter; $counter++; }
18th Mar 2020, 7:17 AM
Raj Chhatrala
Raj Chhatrala - avatar
+ 2
Please elaborate more on the question. Do you want to print it using looping structures? Or just simply print it?
18th Mar 2020, 7:04 AM
Raj Chhatrala
Raj Chhatrala - avatar
0
With looping in php Thanks
18th Mar 2020, 7:13 AM
Putra Cipuik
0
Thanks
18th Mar 2020, 7:22 AM
Putra Cipuik