From 14401b3ace62b2ddeea731f09c627a7a00d9d769 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20Liljenga=CC=8Ard?= Date: Tue, 31 May 2016 09:30:05 +0200 Subject: [PATCH] BasicMath matches all the other files --- src/Numerics/BasicMath.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/Numerics/BasicMath.php b/src/Numerics/BasicMath.php index 4422606..a262544 100644 --- a/src/Numerics/BasicMath.php +++ b/src/Numerics/BasicMath.php @@ -2,18 +2,20 @@ /** * Basic math functions. - * + * * @author Jeff Moser - * @copyright 2010 Jeff Moser + * @copyright 2010 Jeff Moser */ -class BasicMath { +class BasicMath +{ /** * Squares the input (x^2 = x * x) * @param number $x Value to square (x) * @return number The squared value (x^2) */ - public static function square($x) { + public static function square($x) + { return $x * $x; } @@ -23,7 +25,8 @@ class BasicMath { * @param callback $callback The function to apply to each array element before summing. * @return number The sum. */ - public static function sum(array $itemsToSum, $callback) { + public static function sum(array $itemsToSum, $callback) + { $mappedItems = array_map($callback, $itemsToSum); return array_sum($mappedItems); }