local function isWholeNumber(n)
    return type(n) == "number" and n == math.floor(n)
end

local Table = {
    [1] = 0.543,
    [2] = 0.018,
    [3] = 0.173,
    [4] = 0.025,
    [5] = 0.114,
    [6] = .124,
    [7] = 0.003
}

local P = 0
local Divisor1 = 5
local Divisor2 = 6
local Variable1 = 5
local Variable2 = 0

for Outcome, Probability in pairs(Table) do
    --print("Outcome:", Outcome, Divisor / Outcome)
    
    if isWholeNumber(Divisor1 / Outcome) and isWholeNumber(Divisor2 / Outcome) then
        print("Outcome:", Outcome, Divisor1 / Outcome)
        print("Outcome:", Outcome, Divisor2 / Outcome)
        P = P + Probability
    end
end

print("Probability:", P)

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: