- ©«¤l
- 835
- ¥DÃD
- 6
- ºëµØ
- 0
- ¿n¤À
- 915
- ÂI¦W
- 16
- §@·~¨t²Î
- Win 10,7
- ³nÅ骩¥»
- 2019,2013,2003
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2010-5-3
- ³Ì«áµn¿ý
- 2024-11-14
|
¥»©«³Ì«á¥Ñ luhpro ©ó 2013-10-29 23:49 ½s¿è
¦^´_ 3# donod
즡¦³¨Ç¦a¤è¨S¦Ò¼{¶g¨ì, §Ú¤Sקï¤F¤@¤U:- Sub nn()
- Dim iCol%, iCols%, iNum%, iIdx%
- Dim lRow&, lRows&, lSum&(0 To 1)
- Dim bChk(0 To 1) As Boolean
-
- lSum(0) = 0
- lSum(1) = 0
- For lRow = 9 To 11
- bChk(0) = False
- bChk(1) = False
- For iCol = 2 To 18
- With Cells(lRow, iCol)
- If Not .Value = "" Then ' µL¼Æ¦r¤£³B²z
- iIdx = IIf(.Interior.ColorIndex = 43, 1, 0)
- If Left(.Value, 1) = "[" Then
- iNum = Val(Mid(.Value, 2, Len(.Value) - 2))
- Else
- If bChk(iIdx) Then iNum = 0 Else iNum = Val(.Value)
- End If
- If iNum >= Cells(5, 2 + iIdx * 2) Then
- lSum(iIdx) = lSum(iIdx) + Cells(5, 2 + iIdx * 2)
- bChk(iIdx) = True
- ElseIf iNum <= Cells(5, 3 + iIdx * 2) Then
- lSum(iIdx) = lSum(iIdx) + Cells(5, 3 + iIdx * 2)
- bChk(iIdx) = True
- Else
- lSum(iIdx) = lSum(iIdx) + iNum
- End If
- End If
- End With
- Next iCol
- Next lRow
- MsgBox "ºñ¦â®æÁ`¼Æ¬° : " & lSum(1) & Chr(10) & Chr(10) & Chr(10) & "µL¦â®æÁ`¼Æ¬° : " & lSum(0)
- End Sub
½Æ»s¥N½X ¤£¹Lpºâ¥X¨Óªºµ²ªG»P§Aªº¤£¦P,
¬O§Ú¹ï±ø¥óªº±Ôz¦³»~¸Ñ¶Ü?
¥Hºñ¦â®æ¬°¨Ò: (©³¤U²¤¹L«Dºñ¦â®æ©ÎªÅÈ®æ)
²Ä 1 ¦æ - ( D5=33 , E5=-91 )
¡° C9=[-100] ©M=-91 (±ø¥ó5 - ¦pªGºñ¦â®æ¤º¦³[]ªº¼ÆÈ<=E5¡A¥u·íE5ªºÈ¡A¤£»Ýpºâ¨ä¥kÃäµL[]ªº¼ÆÈ, IJµo)
¡° D9=33 (±ø¥ó5 - ²¤¹L)
¡° G9=[35] ©M=-91+33=-58 (±ø¥ó4 - ¦pªGºñ¦â®æ¤º¦³[]ªº¼ÆÈ>=D5¡A¥u·íD5ªºÈ¡A¤£»Ýpºâ¨ä¥kÃäµL[]ªº¼ÆÈ)
¡° H9=-110 (±ø¥ó5 - ²¤¹L)
¡° I9=[32] ©M=-58+32=-26 (±ø¥ó2)
¡° J9=-102 (±ø¥ó5 - ²¤¹L)
²Ä 2 ¦æ -
¡° F10=[-27] ©M=-26+-27=-53 (±ø¥ó2)
¡° G10=135 ©M=-53+33=-20 (±ø¥ó4, IJµo)
¡° M10=[-30] ©M=-20+-30=-50 (±ø¥ó2)
¡° N10=-2 (±ø¥ó4 - ²¤¹L)
²Ä 3 ¦æ -
¡° B11=[-61] ©M=-50+-61=-111 (±ø¥ó2)
¡° C11=-60 ©M=-111+-60=-171 (±ø¥ó2)
¡° O11=[-9] ©M=-171+-9=-180 (±ø¥ó2)
¡° P11=20 ©M=-180+20=-160 (±ø¥ó2)
§Úºâ¥X¨Óªºµ²ªG¬O : -160 »P -56 |
|