{=SUM(vlookup(B2,C1:M5,row(indirect(B3&":"&B4))+1,0))}row(indirect(B3&":"&B4))+1,

来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/25 01:44:16
{=SUM(vlookup(B2,C1:M5,row(indirect(B3&":"&B4))+1,0))}row(indirect(B3&":"&B4))+1,{=SUM(vlookup(B2,C1

{=SUM(vlookup(B2,C1:M5,row(indirect(B3&":"&B4))+1,0))}row(indirect(B3&":"&B4))+1,
{=SUM(vlookup(B2,C1:M5,row(indirect(B3&":"&B4))+1,0))}
row(indirect(B3&":"&B4))+1,

{=SUM(vlookup(B2,C1:M5,row(indirect(B3&":"&B4))+1,0))}row(indirect(B3&":"&B4))+1,
B3和B4里估计是一个类似A1、A2这样的一个文本值,假设B3里是“A1",B4里是“A10",那么
indirect(B3&":"&B4)就等于A1:A10这样的一个区域,这样写的好处是这个区域会根据B3、B4的值来变的.row(indirect(B3&":"&B4))是分别取这个区域里每一行的行号,因为是数组公式,所以才可以用区域作参数.
整个公式就是,根据B2的值,在C1:C5中找到相同的值,然后根据B3、B4的文本值确定的区域的每一行的行号+1,在D1:M5中找到各个数再相加起来,根据公式row(indirect(B3&":"&B4))应该小于11