X-Git-Url: https://pd.if.org/git/?p=pdclib;a=blobdiff_plain;f=functions%2Fmath%2Fhypot.c;h=83dc672f8b46265be2d03b54bf6e9d0393bf6111;hp=449242dfecc51803e94db4bc72d523c68210c9e1;hb=1d9d92ba957a0b8307c9a65c35867fde68e6533b;hpb=34893ecc2200dc7017c36a54cb6c5f4c2378b5ec diff --git a/functions/math/hypot.c b/functions/math/hypot.c index 449242d..83dc672 100644 --- a/functions/math/hypot.c +++ b/functions/math/hypot.c @@ -1,19 +1,17 @@ -// ---------------------------------------------------------------------------- -// $Id$ -// ---------------------------------------------------------------------------- -// Public Domain C Library - http://pdclib.sourceforge.net -// This code is Public Domain. Use, modify, and redistribute at will. -// ---------------------------------------------------------------------------- +/* ---------------------------------------------------------------------------- + * $Id$ + * ---------------------------------------------------------------------------- + * Public Domain C Library - http://pdclib.sourceforge.net + * This code is Public Domain. Use, modify, and redistribute at will. + * --------------------------------------------------------------------------*/ -// ---------------------------------------------------------------------------- -// C++ - -float hypot( float x, float y ) { /* TODO */ }; -long double hypot( long double x, long double y ) { /* TODO */ }; +double hypot( double x, double y ) { /* TODO */ }; -// ---------------------------------------------------------------------------- -// Standard C +/* Therx code +{ + return sqrt( x * x + y * y ); +} +*/ -double hypot( double x, double y ) { /* TODO */ }; float hypotf( float x, float y ) { /* TODO */ }; long double hypotl( long double x, long double y ) { /* TODO */ };