mirror of
https://github.com/DeaDvey/mathgenerator.git
synced 2025-11-28 14:35:23 +01:00
Added Easy Division
This commit is contained in:
@@ -148,6 +148,14 @@ def logFunc(maxBase=3, maxVal=8):
|
||||
solution = str(a)
|
||||
return problem, solution
|
||||
|
||||
def divisionToIntFunc(maxA=25, maxB=25):
|
||||
a = random.randint(1,maxA)
|
||||
b = random.randint(1,maxB)
|
||||
divisor = a*b
|
||||
dividend=random.choice([a,b])
|
||||
problem = f"{divisor}/{dividend} = "
|
||||
solution=int(divisor/dividend)
|
||||
return problem,solution
|
||||
# || Class Instances
|
||||
|
||||
#Format is:
|
||||
|
||||
Reference in New Issue
Block a user