Janilabo

Janilabo | OppositeE() [SCAR Divi]

May 8th, 2013
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pascal 0.52 KB | None | 0 0
  1. {==============================================================================]  
  2.   Explanation: Returns the opposite number of e. -999.9 to 999.9 OR 999.9 to -999.9 (- <=> +)                
  3. [==============================================================================}
  4. function OppositeE(e: Extended): Extended;
  5. begin
  6.   Result := (e * -1);
  7. end;
  8.  
  9. var
  10.   x: Extended;
  11.  
  12. begin
  13.   ClearDebug;
  14.   x := (10.123 + Random(100));
  15.   WriteLn(OppositeE(x));
  16.   x := (x - (200.99 + Random(1000)));
  17.   WriteLn(OppositeE(x));
  18. end.
Advertisement
Add Comment
Please, Sign In to add comment