Sum of square of first n odd numbers | Efficient PHP method to find sum of square of first n odd numbers . ; driver code
< ? php < ? php function squareSum ( $ n ) { return $ n * ( 4 * $ n * $ n - 1 ) / 3 ; } echo squareSum ( 8 ) ; ? >