Private Sub Command1_Click() '等腰三角形
Dim i As Integer, n As Integer
n = 5
For i = 1 To n
Print Space(n - i) String(2 * i - 1, "*")
Next
End Sub
Private Sub Command2_Click() '正方形
Dim i As Integer, n As Integer
n = 5
For i = 伏运培1 To n
For j = 1 To n
缺唯 Print "* "
Next
悄燃Print
Next
End Sub
Private Sub Command3_Click() '等腰梯形
Dim i As Integer, n As Integer, m As Integer
n = 5
m = 5
For i = 1 To n
Print Space(n - i) String(2 * i - 1 + m, "*")
Next
End Sub
'毕指s=(上底+下底)×高÷2private
sub
form_load()
me.show
a
=
val(inputbox("请输入梯形上底"))
b
=
val(inputbox("请输手让配入梯形下底"))
h
=
val(inputbox("请输入梯形的高"))
"梯形上底="
a
"梯形下底="
b
"梯形高="
h
"梯形滑销面积="
(a
+
b)
*
h
/
2
end
sub
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)