SUM |
SUM(number1 [,number2] [..]) |
Returns the total of the numerical values. |
number1 | The first number. |
number2 | (Optional) The second number. |
REMARKS |
* For an illustrated example refer to the page under Advanced Functions * This function includes hidden cells. * Arguments that are just numbers are included. * Arguments that are just numbers passed as text ("3") are included. See Example 15. * Arguments that are just logical values are included. True evaluates to 1. False evaluates to 0. See Example 16. * Arguments that are just text will generate a #VALUE! error. See Example 18. * Arguments that are references to cells containing zeros are included. See Example 9. * Arguments that are references to cells containing dates are included and the date serial number is used. See Example 12. * Arguments that are references to cells containing logical values are excluded. See Example 11. * Arguments that are references to cells containing text are excluded. See Example 10. * Arguments that are references to cells containing error values will be returned. See Example 14. * Arguments that are references to empty cells are excluded. See Example 8. * Arguments that are arrays containing logical values are excluded. See Example 20. * Arguments that are arrays containing text are excluded. See Example 19. * You can have a maximum of 255 arguments. * To sum all the values in column "C" use: "=SUM(C:C)". This function automatically finds the last used row in a column reference. * There is also an AutoSum button to help you enter this function quickly. * You can use the SUMIF function to return the total of the values that satisfies one condition. * You can use the SUMIFS function to return the total of the values that satisfies multiple conditions. * You can use the SUMPRODUCT function to return the sum of the product of one or more arrays of values. * You can use the SUMSQ function to return the sum of the squares of all the values in a list, table or cell range. * You can use the SUMFORMAT - User Defined Function to return the sum of all the values that have been formatted with multiple attributes. * You can use the SUMVISIBLE - User Defined Function to exclude hidden cells. * You can use the DSUM function to return the total of the values in a column that satisfies multiple conditions. * You can use the AGGREGATE function to exclude hidden cells. * This is similar to the AVERAGE, COUNT, MAX, MIN and PRODUCT functions. * For the Microsoft documentation refer to support.microsoft.com * For the Google documentation refer to support.google.com |
|
1 - What is the sum of the values (1,2,3). 2 - What is the sum of the values (1,2,3,0). Zeros are always included. 3 - What is the sum of the values (-2,-3,4,5,6). 4 - What is the sum of the values in the array {-2,-3,4,5,6}. 5 - What is the sum of the values in range "B1:B3". 6 - What is the sum of the values in range "B1", "B2" and "B3". 7 - What is the sum of the values in range "B1", "B2", "B3" and "B4". B4 is empty. Empty cells are always excluded. 8 - What is the sum of the values in range "B1", "B2", "B3" and "B5". B5 is zero so this gets included. 9 - What is the sum of the values in range "B1", "B2", "B3" and "B6". B6 is text so this gets excluded. 10 - What is the sum of the values in range "B1", "B2", "B3" and "B7". B7 is a logical value so this gets excluded. 11 - What is the sum of the values in range "B1", "B2", "B3" and "B8". B8 is a logical value so this gets excluded. 12 - What is the sum of the values in range "B1", "B2", "B3" and "B9". B9 is a date so this gets included as a date serial number. 13 - What is the sum of the values in the named range that refers to the range "B1:B3". 14 - What is the sum of the values in range "B1", "B2", "B3" and "B10". B10 contains an error so that gets returned. 15 - What is the sum of these values (2, "3"). Text values that are actually numbers are included. 16 - What is the sum of these values (2, TRUE). Logical values passed as arguments are included. TRUE is replaced with 1. 17 - What is the sum of these values (2, FALSE). Logical values passed as arguments are included. FALSE is replaced with 0. 18 - What is the sum of these values (2, "some text"). Text values passed as arguments are excluded. 19 - What is the sum of the values in the array {2, "some text"}. Text values inside arrays are excluded. 20 - What is the sum of the values in the array {2, TRUE}. Logical values inside arrays are excluded. |
© 2024 Better Solutions Limited. All Rights Reserved. © 2024 Better Solutions Limited Top