Sha256: 05c5934acc84fd0a3b50c5e579d2ea4fd6b9d2e940a364eda55e9ea2a56ea43f
Contents?: true
Size: 606 Bytes
Versions: 10
Compression:
Stored size: 606 Bytes
Contents
'Arithmetic - Integer Sub RosettaArithmeticInt() Dim opr As Variant, a As Integer, b As Integer On Error Resume Next a = CInt(InputBox("Enter first integer", "XLSM | Arithmetic")) b = CInt(InputBox("Enter second integer", "XLSM | Arithmetic")) Debug.Print "a ="; a, "b="; b, vbCr For Each opr In Split("+ - * / \ mod ^", " ") Select Case opr Case "mod": Debug.Print "a mod b", a; "mod"; b, a Mod b Case "\": Debug.Print "a \ b", a; "\"; b, a \ b Case Else: Debug.Print "a "; opr; " b", a; opr; b, Evaluate(a & opr & b) End Select Next opr End Sub
Version data entries
10 entries across 7 versions & 1 rubygems