php - Add missing elements to an array via function -


i have array of hours/min,

$array = array("09:00","09:05","09:10","09:15","09:20","09:25","09:30","09:35","09:40","09:45","09:50","09:55","10:00","10:05","10:10","10:15","10:20","10:25","10:30","10:35","10:40","10:45","10:50","10:55",15:00","15:05","15:10","15:15","15:20","15:25","15:30","15:35","15:40","15:45","  15:50","15:55","16:00","16:05","16:10","16:15","16:20","16:25","16:30","16:35","16:40","16:45","16:50","16:55");     

how can add missing hours?(from 11:00 14:55) elements differ 5 minutes one-another.

firstly, should be:

$array = array("09:00",...); 

secondly, generate whole array. if absolutely must easiest way loop on array have , add missing items new array, merge them , sort resulting array.


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -