循环法啊
m = 0
For n = 0 To 20 '''一分
For i = 0 To 20 - n ''2分
If n * 1 + i * 2 + (20 - n - i) * 5 = 60 Then
Print "一分:" & n & " 二份" & i & " 五分" & 20 - n - i
m = m + 1
End If
Next
Next
print "共有" & m & "种分法"
循环法啊
m = 0
For n = 0 To 20 '''一分
For i = 0 To 20 - n ''2分
If n * 1 + i * 2 + (20 - n - i) * 5 = 60 Then
Print "一分:" & n & " 二份" & i & " 五分" & 20 - n - i
m = m + 1
End If
Next
Next
print "共有" & m & "种分法"