Digg StumbleUpon LinkedIn YouTube Flickr Facebook Twitter RSS Reset

C/C++: Retourner la valeur absolue d’une varaible de type ‘int’ avec ‘abs()’


{filelink=13989}

 
#include <stdio.h>
#include
<math.h>
 
int main ()
{
  int x, y;
  x = abs( 5 );
  y = abs( -5 );
 
  printf (" x = %dn", x);
  printf (" y = %dn", y);
 
  return 0;
}

No comments yet.

Leave a Comment