0% found this document useful (0 votes)
21 views

Excel Formulas

The document describes various Excel formulas for calculations, text manipulation, dates, and times. Some key formulas include SUM, AVERAGE, and COUNT for calculations; UPPER, LOWER, and PROPER for text; DATE and TIME for dates; and HOUR, MINUTE, and SECOND for extracting time components. These formulas allow users to analyze and manipulate data in Excel worksheets.

Uploaded by

Dhruv Narang
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views

Excel Formulas

The document describes various Excel formulas for calculations, text manipulation, dates, and times. Some key formulas include SUM, AVERAGE, and COUNT for calculations; UPPER, LOWER, and PROPER for text; DATE and TIME for dates; and HOUR, MINUTE, and SECOND for extracting time components. These formulas allow users to analyze and manipulate data in Excel worksheets.

Uploaded by

Dhruv Narang
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 19

Excel Formulas

Calculation Formulas
1. SUM:
The SUM formula calculates the sum of a range of cells. It is commonly used to add up numbers in Excel.
Syntax: =SUM(number1, [number2], ...)
Example: =SUM(A1:A10)
2. MIN:
The MIN formula returns the smallest value in a range of cells. It is useful for finding the minimum value in a set of data.
Syntax: =MIN(number1, [number2], ...)
Example: =MIN(A1:A10)
3. MAX:
The MAX formula returns the largest value in a range of cells. It helps in finding the maximum value in a set of data.
Syntax: =MAX(number1, [number2], ...)
Example: =MAX(A1:A10)
4. AVERAGE:
The AVERAGE formula calculates the average (arithmetic mean) of a range of cells. It is commonly used to find the average value of a set of
numbers.
Syntax: =AVERAGE(number1, [number2], ...)
Example: =AVERAGE(A1:A10)
5. COUNT:
The COUNT formula counts the number of cells that contain numbers. It is used to determine the count of numeric values within a range.
Syntax: =COUNT(value1, [value2], ...)
Example: =COUNT(A1:A10)
6. SUMIF:
The SUMIF formula calculates the sum of a range of cells based on a specified condition. It allows you to sum values that meet a specific
criterion.
Syntax: =SUMIF(range, criteria, [sum_range])
Example: =SUMIF(A1:A10, ">50", B1:B10)
7. SUMIFS:
The SUMIFS formula calculates the sum of a range of cells based on multiple specified conditions. It allows you to sum values that meet
multiple criteria.
Syntax: =SUMIFS(sum_range, criteria_range1, criteria1, [criteria_range2, criteria2], ...)
Example: =SUMIFS(A1:A10, B1:B10, ">50", C1:C10, "Red")
8. AVERAGEIF:
The AVERAGEIF formula calculates the average of a range of cells based on a specified condition. It allows you to find the average value of
cells that meet a specific criterion.
Syntax: =AVERAGEIF(range, criteria, [average_range])
Example: =AVERAGEIF(A1:A10, ">50", B1:B10)
9. MINIFS:
The MINIFS formula returns the smallest value in a range of cells that meet a specified condition.
Syntax: =MINIFS(range, criteria, [min_range])
Example: =MINIFS(A1:A10, B1:B10, ">50")
10. MINIFS:
The MINIFS formula returns the smallest value in a range of cells based on multiple specified conditions.
Syntax: =MINIFS(min_range, criteria_range1, criteria1, [criteria_range2, criteria2], ...)
Example: =MINIFS(A1:A10, B1:B10, ">50", C1:C10, "Red")
11. COUNTIF:
The COUNTIF formula counts the number of cells that meet a specified condition. It allows you to count cells that match a specific criterion.
Syntax: =COUNTIF(range, criteria)
Example: =COUNTIF(A1:A10, ">50")
12. COUNTIFS:
The COUNTIFS formula counts the number of cells that meet multiple specified conditions. It allows you to count cells that match multiple
criteria.
Syntax: =COUNTIFS(criteria_range1, criteria1, [criteria_range2, criteria2], ...)
Example: =COUNTIFS(A1:A10, ">50", B1:B10, "Red")
13. MAXIFS:
The MAXIFS formula returns the largest value in a range of cells that meet a specified condition.
Syntax: =MAXIFS(range, criteria, [min_range])
Example: =MAXIFS(A1:A10, B1:B10, ">50")
14. MAXIFS:
The MAXIFS formula returns the largest value in a range of cells based on multiple specified conditions.
Syntax: =MAXIFS(min_range, criteria_range1, criteria1, [criteria_range2, criteria2], ...)
Example: =MAXIFS(A1:A10, B1:B10, ">50", C1:C10, "Red")
15. COUNTA Formula:
The COUNTA formula is used to count the number of non-blank cells within a given range. It counts all cells that contain any type of data,
including text, numbers, logical values, errors, and empty strings. The basic syntax for the COUNTA formula is "=COUNTA(range)".
For example, if you have a range of cells A1 to A5 where A1, A2, and A4 contain data, and A3 and A5 are empty, the formula "=COUNTA(A1:A5)"
will return 3 as the result.
16. COUNTBLANK Formula:
The COUNTBLANK formula is used to count the number of blank cells within a given range. It counts cells that contain no data or empty strings.
The basic syntax for the COUNTBLANK formula is "=COUNTBLANK(range)".
For instance, if you have a range of cells A1 to A5 where A1, A3, and A5 are blank, and A2 and A4 contain data, the formula
"=COUNTBLANK(A1:A5)" will return 3 as the result.
Text Formulas.

1. TEXT:
The TEXT formula converts a numeric value to text using a specified format. It is used to format numbers, dates, and times as text.
Syntax: =TEXT(value, format_text)
Example: =TEXT(A1, "0.00")
2. UPPER:
The UPPER formula converts text to uppercase. It is useful for converting lowercase or mixed-case text to uppercase.
Syntax: =UPPER(text)
Example: =UPPER(A1)
3. LOWER:
The LOWER formula converts text to lowercase. It is useful for converting uppercase or mixed-case text to lowercase.
Syntax: =LOWER(text)
Example: =LOWER(A1)
4. PROPER:
The PROPER formula capitalizes the first letter of each word in a text string. It is commonly used for proper noun capitalization.
Syntax: =PROPER(text)
Example: =PROPER(A1)
5. LEFT:
The LEFT formula extracts a specified number of characters from the beginning of a text string.
Syntax: =LEFT(text, num_chars)
Example: =LEFT(A1, 5)
6. RIGHT:
The RIGHT formula extracts a specified number of characters from the end of a text string.
Syntax: =RIGHT(text, num_chars)
Example: =RIGHT(A1, 3)
7. MID:
The MID formula extracts a specified number of characters from a text string, starting at a specified position.
Syntax: =MID(text, start_num, num_chars)
Example: =MID(A1, 3, 5)
8. CHAR:
The CHAR formula returns the character specified by the ASCII value. It is used to get special characters based on their ASCII codes.
Syntax: =CHAR(number)
Example: =CHAR(65)
9. FIND:
The FIND formula searches for a specific text within another text and returns the starting position of the found text.
Syntax: =FIND(find_text, within_text, [start_num])
Example: =FIND("apple", A1)
10. SEARCH:
The SEARCH formula searches for a specific text within another text, similar to FIND, but it is not case-sensitive.
Syntax: =SEARCH(find_text, within_text, [start_num])
Example: =SEARCH("apple", A1)
11. REPLACE:
The REPLACE formula replaces a specific part of a text string with another text.
Syntax: =REPLACE(old_text, start_num, num_chars, new_text)
Example: =REPLACE(A1, 3, 2, "123")
12. SUBSTITUTE:
The SUBSTITUTE formula replaces specific instances of a text string within another text with a new text.
Syntax: =SUBSTITUTE(text, old_text, new_text, [instance_num])
Example: =SUBSTITUTE(A1, "apple", "banana")
13. CONCATENATE Formula:
The CONCATENATE formula is used to combine multiple text strings or cell values into a single string. It allows you to join different text values
or cell contents together. The basic syntax for the CONCATENATE formula is "=CONCATENATE(text1, text2, ...)".
For instance, if you have the text "Hello" in cell A1 and "World" in cell B1, the formula "=CONCATENATE(A1, " ", B1)" will result in "Hello
World".
14. TEXTJOIN:
The TEXTJOIN formula combines multiple text strings into a single text string, separated by a specified delimiter.
Syntax: =TEXTJOIN(delimiter, ignore_empty, text1, [text2], ...)
Example: =TEXTJOIN(", ", TRUE, A1:A5)
15. LEN Formula:
The LEN formula is used to calculate the length of a text string. It returns the number of characters in the text string, including spaces and
punctuation marks. The basic syntax for the LEN formula is "=LEN(text)".
For example, if you have the text "Hello" in cell A1, the formula "=LEN(A1)" will return 5 as the result.
16. REPT Formula:
The REPT formula is used to repeat a text string a specified number of times. It allows you to create a repeated string. The basic syntax for the
REPT formula is "=REPT(text, number_times)".
If you want to repeat the text "Hello" three times, you can use the formula "=REPT("Hello", 3)", and it will result in "HelloHelloHello".
17. TRIM Formula:
The TRIM formula is used to remove extra spaces from a text string, except for single spaces between words. It helps to clean up text by
removing leading, trailing, and excessive spaces. The basic syntax for the TRIM formula is "=TRIM(text)".
For instance, if you have the text " Hello World " in cell A1, the formula "=TRIM(A1)" will remove the extra spaces and return "Hello World".
Date and time
1. DATE:
The DATE formula creates a date by specifying the year, month, and day as separate arguments.
Syntax: =DATE(year, month, day)
Example: =DATE(2023, 5, 25)
2. TIME:
The TIME formula creates a time by specifying the hour, minute, and second as separate arguments.
Syntax: =TIME(hour, minute, second)
Example: =TIME(9, 30, 0)
3. DATEVALUE:
The DATEVALUE formula converts a date in text format to a serial number that Excel recognizes as a date.
Syntax: =DATEVALUE(date_text)
Example: =DATEVALUE("25-May-2023")
4. TIMEVALUE:
The TIMEVALUE formula converts a time in text format to a serial number that Excel recognizes as a time.
Syntax: =TIMEVALUE(time_text)
Example: =TIMEVALUE("09:30 AM")
5. HOUR:
The HOUR formula extracts the hour component from a specified time.
Syntax: =HOUR(time)
Example: =HOUR(A1)
6. MINUTE:
The MINUTE formula extracts the minute component from a specified time.
Syntax: =MINUTE(time)
Example: =MINUTE(A1)
7. SECOND:
The SECOND formula extracts the second component from a specified time.
Syntax: =SECOND(time)
Example: =SECOND(A1)
8. DAY:
The DAY formula extracts the day of the month from a specified date.
Syntax: =DAY(date)
Example: =DAY(A1)
9. MONTH:
The MONTH formula extracts the month from a specified date.
Syntax: =MONTH(date)
Example: =MONTH(A1)
10. YEAR:
The YEAR formula extracts the year from a specified date.
Syntax: =YEAR(date)
Example: =YEAR(A1)
11. DATEDIF:
The DATEDIF formula calculates the difference between two dates in various units (days, months, or years).
Syntax: =DATEDIF(start_date, end_date, unit)
Example: =DATEDIF(A1, A2, "d")
12. WORKDAYS:
The WORKDAYS formula calculates the number of working days between two dates, excluding weekends and optionally, specified holidays.
Syntax: =WORKDAYS(start_date, end_date, [holidays])
Example: =WORKDAYS(A1, A2, B1:B5)
13. NETWORKDAYS:
The NETWORKDAYS formula calculates the number of working days between two dates, excluding weekends and specified holidays.
Syntax: =NETWORKDAYS(start_date, end_date, [holidays])
Example: =NETWORKDAYS(A1, A2, B1:B5)
14. DAYS:
The DAYS formula calculates the number of days between two dates.
Syntax: =DAYS(end_date, start_date)
Example: =DAYS(A2, A1)
15. MONTHS:
The MONTHS formula calculates the number of months between two dates.
Syntax: =MONTHS(end_date, start_date)
Example: =MONTHS(A2, A1)
The EOMONTH formula in Excel is a useful function that allows you to determine the end of the month for a given date. It is particularly helpful
when working with financial or project planning, as it helps calculate due dates, end dates, or perform date-based calculations.
The syntax for the EOMONTH formula is as follows:
=EOMONTH(start_date, months)
Here's a breakdown of the components:

start_date: This is the initial date or the starting point from which you want to calculate the end of the month.

months: This represents the number of months to move forward or backward from the start_date. Positive values indicate future months,
while negative values indicate past months.
The EOMONTH formula returns the last day of the month that is the specified number of months away from the start_date.
16. TODAY Formula:
The TODAY formula is used to insert the current date into a cell. It automatically updates the date whenever the worksheet is recalculated or
opened. The basic syntax for the TODAY formula is "=TODAY()".
If you enter the formula "=TODAY()" in a cell, it will display the current date.
17. NOW Formula:
The NOW formula is used to insert the current date and time into a cell. It automatically updates the date and time whenever the worksheet
is recalculated or opened. The basic syntax for the NOW formula is "=NOW()".
If you enter the formula "=NOW()" in a cell, it will display the current date and time.
18. EDATE Formula:
The EDATE formula is used to calculate a date that is a specified number of months before or after a given date. It is useful for performing
date-based calculations. The basic syntax for the EDATE formula is "=EDATE(start_date, months)".
For example, if you have a start date in cell A1 and you want to add 6 months to it, you can use the formula "=EDATE(A1, 6)", and it will return
the date that is 6 months after the start date.
Other Formulas
1. ISTEXT Formula:
The ISTEXT formula is used to check whether a cell contains text or not. It returns TRUE if the cell contains text and FALSE if it contains any
other data type. The basic syntax for the ISTEXT formula is "=ISTEXT(value)".
For example, if you want to check if cell A1 contains text, you can use the formula "=ISTEXT(A1)". If A1 contains text, the formula will return
TRUE; otherwise, it will return FALSE.
2. ISNUMBER Formula:
The ISNUMBER formula is used to check whether a cell contains a numeric value or not. It returns TRUE if the cell contains a number and
FALSE if it contains any other data type. The basic syntax for the ISNUMBER formula is "=ISNUMBER(value)".
For instance, if you want to check if cell A1 contains a number, you can use the formula "=ISNUMBER(A1)". If A1 contains a number, the
formula will return TRUE; otherwise, it will return FALSE.
3. ISBLANK Formula:
The ISBLANK formula is used to check whether a cell is blank or not. It returns TRUE if the cell is empty or contains no data and FALSE if it
contains any type of data. The basic syntax for the ISBLANK formula is "=ISBLANK(value)".
For example, if you want to check if cell A1 is blank, you can use the formula "=ISBLANK(A1)". If A1 is blank, the formula will return TRUE;
otherwise, it will return FALSE.
4. ROW Formula:
The ROW formula is used to return the row number of a cell reference. It returns the row number of the cell in which the formula is entered.
The basic syntax for the ROW formula is "=ROW([reference])".
If you enter the formula "=ROW(A1)" in cell B1, it will return 1 since it is the row number of cell A1.
5. COLUMN Formula:
The COLUMN formula is used to return the column number of a cell reference. It returns the column number of the cell in which the formula
is entered. The basic syntax for the COLUMN formula is "=COLUMN([reference])".
If you enter the formula "=COLUMN(A1)" in cell B1, it will return 1 since it is the column number of cell A1.
6. ROWS Formula:
The ROWS formula is used to count the number of rows in a range or array. It returns the total number of rows covered by the given range or
array. The basic syntax for the ROWS formula is "=ROWS(range)".
For example, if you have a range of cells A1 to A5, the formula "=ROWS(A1:A5)" will return 5 as the result, indicating the total number of rows
in the range.
7. COLUMNS Formula:
The COLUMNS formula is used to count the number of columns in a range or array. It returns the total number of columns covered by the
given range or array. The basic syntax for the COLUMNS formula is "=COLUMNS(range)".
If you have a range of cells A1 to D1, the formula "=COLUMNS(A1:D1)" will return 4 as the result, indicating the total number of columns in
the range.
8. MATCH:
The MATCH formula searches for a specified value in a range of cells and returns its relative position.
Syntax: =MATCH(lookup_value, lookup_array, [match_type])
Example: =MATCH(A1, A1:A10, 0)

19. RANDBETWEEN Formula:


The RANDBETWEEN formula is used to generate a random integer between two specified values. It is useful for creating random data or
simulations. The basic syntax for the RANDBETWEEN formula is "=RANDBETWEEN(bottom, top)".
For instance, if you want to generate a random number between 1 and 100, you can use the formula "=RANDBETWEEN(1, 100)", and it will
return a random integer within that range.
10. EXACT Formula:
The EXACT formula is used to compare two text strings and determine if they are exactly the same. It is case-sensitive, so it distinguishes
between uppercase and lowercase characters. The basic syntax for the EXACT formula is "=EXACT(text1, text2)".
If you want to compare the text in cell A1 with the text in cell B1, you can use the formula "=EXACT(A1, B1)". If the two text strings are exactly
the same, the formula will return TRUE; otherwise, it will return FALSE.
11. IF Formula:
The IF formula is used to perform conditional evaluations and return different values based on a specified condition. It allows you to perform
different actions based on whether a condition is true or false. The basic syntax for the IF formula is "=IF(logical_test, value_if_true,
value_if_false)".
For example, if you want to check if a value in cell A1 is greater than 10, you can use the formula "=IF(A1>10, "Yes", "No")". If the value in A1
is greater than 10, the formula will return "Yes"; otherwise, it will return "No".
12. IFS Formula:
The IFS formula is used to perform multiple conditional evaluations and return different values based on multiple conditions. It is an extended
version of the IF formula and allows you to test multiple conditions in a single formula. The basic syntax for the IFS formula is
"=IFS(logical_test1, value_if_true1, logical_test2, value_if_true2, ...)".
For instance, if you want to check multiple conditions and return different values accordingly, you can use the formula "=IFS(A1>10, "High",
A1>5, "Medium", A1<=5, "Low")". It will evaluate the conditions in order and return the corresponding value based on the first condition that
is true.
13. SWITCH Formula:
The SWITCH formula is used to test a single value against multiple conditions and return different results based on the matching condition. It
simplifies multiple nested IF statements. The basic syntax for the SWITCH formula is "=SWITCH(expression, value1, result1, value2, result2,
...)".
For example, if you have a value in cell A1 and want to return different results based on its value, you can use the formula "=SWITCH(A1, 1,
"One", 2, "Two", 3, "Three", "Other")". It will evaluate the expression (A1) against the provided values and return the corresponding result.
22. CHOOSE Formula:
The CHOOSE formula is used to select and return a value from a list of values based on a specified index number. It allows you to choose a
value from a list based on its position. The basic syntax for the CHOOSE formula is "=CHOOSE(index_num, value1, value2, ...)".
If you have a list of values in cells A1 to A5 and want to select a value based on an index number in cell B1, you can use the formula
"=CHOOSE(B1, A1, A2, A3, A4, A5)". It will return the value at the specified index number.
14. VLOOKUP Formula:
The VLOOKUP formula is used to search for a value in the leftmost column of a table and return a corresponding value from a specified column.
It is commonly used for table lookups. The basic syntax for the VLOOKUP formula is "=VLOOKUP(lookup_value, table_range, col_index,
[range_lookup])".
The "lookup_value" is the value you want to search for, "table_range" is the range of cells that contains the table data, "col_index" specifies
which column from the table_range you want to retrieve, and "range_lookup" is an optional argument that specifies whether to perform an
exact match or an approximate match.
15. HLOOKUP Formula:
The HLOOKUP formula is used to search for a value in the top row of a table and return a corresponding value from a specified row. It works
similar to the VLOOKUP formula, but the search is performed horizontally instead of vertically. The basic syntax for the HLOOKUP formula is
"=HLOOKUP(lookup_value, table_range, row_index, [range_lookup])".
The "lookup_value" is the value you want to search for, "table_range" is the range of cells that contains the table data, "row_index" specifies
which row from the table_range you want to retrieve, and "range_lookup" is an optional argument that specifies whether to perform an exact
match or an approximate match.
16. INDEX Formula:
The INDEX formula is used to retrieve a value from a specified range based on its row and column numbers. It is useful for looking up values
in a two-dimensional range. The basic syntax for the INDEX formula is "=INDEX(array, row_num, [column_num])".
The "array" is the range of cells from which you want to retrieve the value, "row_num" specifies the row number in the array, and
"column_num" specifies the column number in the array. If the "column_num" argument is omitted, the formula will return the entire row
specified by the "row_num".
17. AND Formula:
The AND formula is used to test multiple conditions and return TRUE if all the conditions are true, or FALSE if any of the conditions are false.
It is commonly used in conjunction with other functions or formulas. The basic syntax for the AND formula is "=AND(logical1, logical2, ...)".
For example, if you want to check if two conditions in cells A1 and B1 are both true, you can use the formula "=AND(A1>10, B1<20)". It will
return TRUE only if both conditions are true; otherwise, it will return FALSE.
18. OR Formula:
The OR formula is used to test multiple conditions and return TRUE if any of the conditions are true, or FALSE if all the conditions are false. It
is commonly used in conjunction with other functions or formulas. The basic syntax for the OR formula is "=OR(logical1, logical2, ...)".
If you want to check if either of two conditions in cells A1 and B1 is true, you can use the formula "=OR(A1>10, B1<20)". It will return TRUE if
at least one of the conditions is true; otherwise, it will return FALSE.
19. LARGE Formula:
The LARGE formula is used to return the nth largest value from a range or array of values. It is useful for finding the top or bottom values in a
dataset. The basic syntax for the LARGE formula is "=LARGE(array, k)".
The "array" is the range or array of values from which you want to find the nth largest value, and "k" specifies the position of the value you
want to retrieve. For example, "=LARGE(A1:A10, 3)" will return the third largest value in the range A1 to A10.
20. INDIRECT Formula:
The INDIRECT formula is used to convert a text string into a valid cell reference. It allows you to create dynamic references based on the
contents of other cells. The basic syntax for the INDIRECT formula is "=INDIRECT(ref_text, [a1])".
The "ref_text" is the text string that represents the cell reference you want to create, and the "a1" is an optional argument that specifies the
type of cell reference to return (TRUE for A1-style reference, FALSE or omitted for R1C1-style reference).
For example, if you have the text "A1" in cell B1, you can use the formula "=INDIRECT(B1)" in another cell to refer to the value in cell A1
dynamically.

You might also like