Using Variables in Summing Formulas in Excel/Open Calc

AI Thread Summary
In Excel, to sum a range where the endpoint is determined by a variable, the INDIRECT function is essential. For instance, to sum from A1 to a cell defined by A1 plus a value in F4, the correct formula is =SUM(INDIRECT("A1:A"&F4)). The ampersand (&) is used for concatenation, not the plus sign (+), which is crucial for constructing the range correctly. Using the incorrect formula, such as SUM(A1:A(1+F4)), will result in a number error.
Kuryakin
Messages
10
Reaction score
0
In excel, using Open Calc but I assume they're the same.

Is their a way to put variables value into summing formulas. I wanted to sum from A1 to an A cell which is numbered A1+F4. So if F4 = 100 I'd want to SUM(A1:A101)
I tried SUM(A1:A(1+F4)) but it gives a number error
 
Computer science news on Phys.org
Hi, ok you need to use a function called "INDIRECT()".

Example: =SUM(INDIRECT("A1:A"&F4))

Note: & is the concatenation operator, not +.
 
Thank-you.
 
SUM(A1:A(1+F4)) this formula i don't think is correct.
simply use with + sign
 
This week, I saw a documentary done by the French called Les sacrifiés de l'IA, which was presented by a Canadian show Enquête. If you understand French I recommend it. Very eye-opening. I found a similar documentary in English called The Human Cost of AI: Data workers in the Global South. There is also an interview with Milagros Miceli (appearing in both documentaries) on Youtube: I also found a powerpoint presentation by the economist Uma Rani (appearing in the French documentary), AI...
Thread 'Urgent: Physically repair - or bypass - power button on Asus laptop'
Asus Vivobook S14 flip. The power button is wrecked. Unable to turn it on AT ALL. We can get into how and why it got wrecked later, but suffice to say a kitchen knife was involved: These buttons do want to NOT come off, not like other lappies, where they can snap in and out. And they sure don't go back on. So, in the absence of a longer-term solution that might involve a replacement, is there any way I can activate the power button, like with a paperclip or wire or something? It looks...
Back
Top