Function Problems

Calculate the Difference Between the Highest and Lowest Values in a Row in WPS Spreadsheets

Muhammad TalhaMuhammad Talha Dec 2, 2026 869 views

Question details

Automatically calculate the difference between the highest and lowest values in a row.

Calculate the Difference Between the Highest and Lowest Values in a Row
Product
Spreadsheet software, such as WPS Spreadsheets or Microsoft Excel
Device & OS
not provided
Scenario
A result cell should calculate the range of values in a row instead of containing a manually entered number.
Observed behavior
The result cell should update automatically when the values in the selected row change.
Before you start

Identify the cells in the row that should be included, and choose a result cell outside that range. Check that the values are stored as numbers rather than text.

Solution 1Recommended

Subtract the Row Minimum from the Maximum

Use this formula to calculate the difference across a continuous range of cells.

1
Select the result cell

Click an empty cell outside the range you want to calculate.

2
Enter the formula

Type =MAX(B10:K10)-MIN(B10:K10) in the cell or formula bar. Replace B10:K10 with the row range you want to use.

3
Calculate the result

Press Enter. The result updates when numeric values in the referenced range change.

Subtract the Row Minimum from the Maximum
Check the selected cells: The formula includes every numeric value in the specified range, regardless of cell highlighting.
Calculate with WPS Spreadsheets

Calculate Row Differences Automatically in WPS Spreadsheets

Use MAX and MIN in WPS Spreadsheets to calculate the difference between the highest and lowest values in a row and keep the result updated.

  1. 1. Open your spreadsheet: Open WPS Spreadsheets and select your workbook from Open.
  2. 2. Select a result cell: Click an empty cell outside the row range you want to compare.
  3. 3. Enter the formula: Type =MAX(B10:K10)-MIN(B10:K10), replacing the example range with your own.
  4. 4. Confirm the calculation: Press Enter to display the difference.
Calculate row differences with a single formulaRecalculate results when referenced values changeOpen and edit Microsoft Excel XLSX and XLS files
microsoft office alternative - wps office

Frequently Asked Questions

Will the result update when I change a value?

Yes. The MAX and MIN formula recalculates when values in the referenced cells change, provided automatic calculation is enabled.

How do I include only certain cells in the row?

List the same selected references in both functions, for example, =MAX(B10,D10,K10)-MIN(B10,D10,K10).

Does the formula include only highlighted cells?

No. MAX and MIN use the cell references in the formula, not their highlight colors. List the highlighted cells explicitly if only those cells should be included.

Can I use the same formula in Microsoft Excel?

Yes. Enter the same MAX and MIN formula in an Excel result cell, replacing B10:K10 with your range.