Duio.php
// Splits an array vertically into two arrays.
Splits an array vertically into two arrays.
Splits an array vertically into two arrays .
public function verticalSplit($by, $arr)
      {
        $f = $s = [];
        foreach ($arr as $index => $val):
          array_push($f, explode($by, $val)[0]);
          array_push($s, explode($by, $val)[1]);
        endforeach;
        return [$f, $s];
      }
public function verticalSplit ( $ by , $ arr ) { $ f = $ s = [ ] ; foreach ( $ arr as $ index => $ val ) : array_push ( $ f , explode ( $ by , $ val ) [ 0 ] ) ; array_push ( $ s , explode ( $ by , $ val ) [ 1 ] ) ; endforeach ; return [ $ f , $ s ] ; }
Splits an array vertically into two arrays.
Splits an array vertically into two arrays .