data structures and algorithms in php