home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / vc98 / include / minmax.h < prev    next >
C/C++ Source or Header  |  1998-06-16  |  467b  |  29 lines

  1. /***
  2. *minmax.h - familiar min & max macros
  3. *
  4. *       Copyright (c) 1985-1997, Microsoft Corporation. All rights reserved.
  5. *
  6. *Purpose:
  7. *       Defines min and max macros.
  8. *
  9. *       [Public]
  10. *
  11. ****/
  12.  
  13. #if     _MSC_VER > 1000
  14. #pragma once
  15. #endif
  16.  
  17. #ifndef _INC_MINMAX
  18. #define _INC_MINMAX
  19.  
  20. #ifndef max
  21. #define max(a,b)            (((a) > (b)) ? (a) : (b))
  22. #endif
  23.  
  24. #ifndef min
  25. #define min(a,b)            (((a) < (b)) ? (a) : (b))
  26. #endif
  27.  
  28. #endif
  29.