N Function - Excel
Overview
The N function in Excel is a useful tool for converting different types of values into a number. This function will return a numeric value when given a variety of inputs.
A numerical value will return a numerical value.
TRUE will return a value of 1, FALSE will return a value of 0.
Any type of text will return a value of 0.
A date will return the serial number value for that date.
Example:
=N("TRUE")
Syntax:
=N(value)
value
: This is the value or expression that you want to convert to a number.
Example: Numerical input
In this example, the N function returns a numerical value for the numerical value.
Example: TRUE or FALSE input
In this example, the N function returns the value of 1 for TRUE and a 0 for FALSE.
Example: Text input
In this example, the N function returns the value of 0 for a text input.
Example: Date input
In this example, the N function returns the value of the serial number of the date input.