Originally Posted by randall I have also wrote a sqrt function... my one: PHP Code: sqrt( x ) { y = x; for( z = x *0.25 ; abs( z - y ) >= 0.001 ; y = ( z + ( x / z ) ) * 0.5 ) { z = y; } return y; }
sqrt( x ) { y = x; for( z = x *0.25 ; abs( z - y ) >= 0.001 ; y = ( z + ( x / z ) ) * 0.5 ) { z = y; } return y; }
kung foo man (19th May 2013),Ni3ls (19th May 2013),randall (20th May 2013)
Forum Rules