#include<iostream.h>
#include<conio.h>
#include<stdlib.h> // defines the labs( ) function
void main ( )
{
long i ;
i = -12345678L ;
cout<<"\n i = "<<i ;
cout<<"\n Absolute value of i = "<<labs(i);
i = 12345678L ;
cout<<"\n\n i = "<<i ;
cout<<"\n Absolute value of i = "<<labs(i);
getch() ;
}
0 comments:
Post a Comment