[ create a new paste ] login | about

Link: http://codepad.org/RPmZUWjA    [ raw code | output | fork ]

PHP, pasted on Mar 25:
1
2
3
4
5
6
7
8
9
<?php

$array = array(2708100, 2708663, 2712155);

for($i = 1; $i < count($array); $i++) {
  $resultado[] = $array[$i] - $array[$i - 1];
}

echo array_sum($resultado)/count($resultado);


Output:
1
2027.5


Create a new paste based on this one


Comments: