Скрипт
a =
script.Parent.A
b =
script.Parent.B
c =
script.Parent.C
butPlus
= script.Parent.PLUS
butMinus
= script.Parent.MINUS
butMul
= script.Parent.MUL
butDiv
= script.Parent.DIV
butClear
= script.Parent.CLEAR
function
Plus()
c.Text = a.Text + b.Text
end
function
Minus()
c.Text = a.Text - b.Text
end
function
Mul()
c.Text = a.Text * b.Text
end
function
Div()
c.Text = a.Text / b.Text
end
function
Clear()
a.Text=0
b.Text=0
c.Text=0
end
butPlus.MouseButton1Click:Connect(Plus)
butMinus.MouseButton1Click:Connect(Minus)
butMul.MouseButton1Click:Connect(Mul)
butDiv.MouseButton1Click:Connect(Div)
butClear.MouseButton1Click:Connect(Clear)
Немає коментарів:
Дописати коментар