MS Excel: MOD Function (WS)
The Microsoft Excel MOD function returns the remainder after a number is divided by a divisor.
MOD Function (Syntax)
The syntax for the Microsoft Excel MOD function is:
MOD( number, divisor )
number is a numeric value whose remainder you wish to find.
divisor is the number used to divide the number parameter. If the divisor is 0, then the MOD function will return the #DIV/0! error.
The MOD function can be used in the following versions of Microsoft Excel:
- Excel 2013, Excel 2011 for Mac, Excel 2010, Excel 2007, Excel 2003, Excel XP, Excel 2000
Type of Excel Function
The MOD function can be used in Microsoft Excel as:
- Worksheet function (WS)
MOD Examples (as Worksheet Function)
Let's look at some Excel MOD function examples and explore how you would use the MOD function as a worksheet function in Microsoft Excel:
Based on the Excel spreadsheet above, the following MOD function examples would return:
|=MOD(A1, A2)||would return 2|
|=MOD(A1, A3)||would return -7|
|=MOD(34, A2)||would return 0|
|=MOD(34, 0)||would return #DIV/0!|