Sub abc()
Dim s As Double, n As Integer, i As Integer
n = CInt(InputBox("Задайте значение n"))
For i = 1 To n
s = s + 1 / i
Next i
MsgBox "Сумма равна " & CStr(s)
End Sub
Sub abc()
Dim s As Double, n As Integer, i As Integer
n = CInt(InputBox("Задайте значение n"))
For i = 1 To n
s = s + 1 / i
Next i
MsgBox "Сумма равна " & CStr(s)
End Sub