Data update
This commit is contained in:
parent
4d5544505c
commit
4924dd0264
3073 changed files with 55820 additions and 4408 deletions
13
Task/Arithmetic-Integer/Pluto/arithmetic-integer.pluto
Normal file
13
Task/Arithmetic-Integer/Pluto/arithmetic-integer.pluto
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
local function divmod(a, b) return { a // b, a % b } end
|
||||
|
||||
io.write("Input the first integer : ")
|
||||
local a = io.read("n")
|
||||
io.write("Input the second integer: ")
|
||||
local b = io.read("n")
|
||||
print($"sum: {a + b}")
|
||||
print($"difference {a - b}")
|
||||
print($"product {a * b}")
|
||||
print($"quotient {a // b}")
|
||||
print($"remainder {a % b}")
|
||||
print($"exponentation {math.tointeger(a ^ b)}")
|
||||
print($"divmod {divmod(a, b):concat(", ")}")
|
||||
Loading…
Add table
Add a link
Reference in a new issue