Skip to content

Latest commit

 

History

History
58 lines (48 loc) · 1.54 KB

File metadata and controls

58 lines (48 loc) · 1.54 KB
title ms.custom ms.date ms.reviewer ms.suite ms.technology ms.tgt_pltfrm ms.topic apiname apilocation apitype f1_keywords dev_langs helpviewer_keywords ms.assetid caps.latest.revision author ms.author manager
__max | Microsoft Docs
11/04/2016
cpp-standard-libraries
article
__max
msvcrt.dll
msvcr80.dll
msvcr90.dll
msvcr100.dll
msvcr100_clr0400.dll
msvcr110.dll
msvcr110_clr0400.dll
msvcr120.dll
msvcr120_clr0400.dll
ucrtbase.dll
DLLExport
max
__max
C++
max macro
maximum macro
__max macro
05c936f6-0e22-45d6-a58d-4bc102e9dae2
12
corob-msft
corob
ghogen

__max

Returns the larger of two values.

Syntax

type __max(  
   type a,  
   type b   
);  

Parameters

type
Any numeric data type.

a, b
Values of any numeric type to be compared.

Return Value

__max returns the larger of its arguments.

Remarks

The __max macro compares two values and returns the value of the larger one. The arguments can be of any numeric data type, signed or unsigned. Both arguments and the return value must be of the same data type.

Requirements

Routine Required header
__max <stdlib.h>

Example

For more information, see the example for __min.

See Also

Floating-Point Support
__min