mirror of
https://github.com/DeaDvey/mathgenerator.git
synced 2025-11-28 06:25:23 +01:00
12 lines
353 B
Python
12 lines
353 B
Python
from .__init__ import *
|
|
|
|
|
|
def decimalToOctalFunc(maxDecimal=4096):
|
|
x = random.randint(0, maxDecimal)
|
|
problem = "The decimal number " + str(x) + " in Octal is: "
|
|
solution = oct(x)
|
|
return problem, solution
|
|
|
|
|
|
decimalToOctal = Generator("Converts decimal to octal", 82, "What's the octal representation of 98?", "0o142", decimalToOctalFunc)
|