Math table sums with adding all except last digit to next column

bruno12

New Member
Joined
Jan 13, 2017
Messages
4
I have a task to solve in excel for my homework.
I have a table with 9 columns with different values of whole numbers.
I have to sum up each column and if sum is larger than 1 digit all except last digit shuold be added to the sum of the next column on the left.
for example:
If sum of column 9 is 107 , leave 7 and add 10 (ten) to the sum on the left.
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
I have a task to solve in excel for my homework.

Check out the LEN function to show you the number of characters in a reference. For example, if the sum of A1 through A10 is 107, =LEN(SUM(A1:A10)) will return 3.
Also look at the LEFT function to pull out a certain number of characters from the left of the string. For example, =LEFT(107,2) will return 10.

Good luck!
 
Last edited:
Upvote 0
Thanks for help , much appreciated :)
Here is my solution: (maybe someone can simplify it lol)
for column M ( the last one on the right in my table) =IF(LEN(SUM(M54:M67))>1,RIGHT(SUM(M54:M67),LEN(SUM(M54:M67))-1),SUM(M54:M67))
for column L =IF(LEN(SUM(L54:L67))>1,RIGHT(SUM(L54:L67),(LEN(SUM(L54:L67))-1)),SUM(L54:L67))+IF(LEN(SUM(M54:M67))>1,LEFT(SUM(M54:M67),LEN(SUM(M54:M67))-1),0)
etc...
Best regards
 
Upvote 0
not there yet , formula from above isnt working with cases where large numbers are transfered to the left.
 
Upvote 0
this one works! :)
column M in my case is the last column on the right side :
If number of digits of the sum of column M is larger than 1, show last digit on the right side only , otherwise show sum.
=IF(LEN(SUM(M54:M67))>1,RIGHT(SUM(M54:M67),LEN(SUM(M54:M67))-(LEN(SUM(M54:M67))-1)),SUM(M54:M67))
column L has a task to sum + add value from column M with given criteria . (if sum is 107 it adds 10 to column L)
if number of digits (LEN) of sum of column L and number given from column M( in case sum of column M is larger than 9 -LEN>1) is greater than 1 write down only last digit.
=IF(LEN(SUM(L54:L67)+IF(LEN(SUM(M54:M67))>1,LEFT(SUM(M54:M67),LEN(SUM(M54:M67))-(LEN(SUM(M54:M67))-1)),0))>1,RIGHT(SUM(L54:L67)+IF(LEN(SUM(M54:M67))>1,LEFT(SUM(M54:M67),LEN(SUM(M54:M67))-(LEN(SUM(M54:M67))-1)),0),LEN(SUM(L54:L67)+IF(LEN(SUM(M54:M67))>1,LEFT(SUM(M54:M67),LEN(SUM(M54:M67))-(LEN(SUM(M54:M67))-1)),0))-(LEN(SUM(L54:L67)+IF(LEN(SUM(M54:M67))>1,LEFT(SUM(M54:M67),LEN(SUM(M54:M67))-(LEN(SUM(M54:M67))-1)),0))-1)),SUM(L54:L67)+IF(LEN(SUM(M54:M67))>1,LEFT(SUM(M54:M67),LEN(SUM(M54:M67))-(LEN(SUM(M54:M67))-1)),0))
 
Upvote 0

Forum statistics

Threads
1,214,561
Messages
6,120,231
Members
448,951
Latest member
jennlynn

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top