Solve problem 121 in Python and update template creation lib
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
FROM = 206
|
||||
TILL = 206
|
||||
FROM = 100
|
||||
TILL = 100
|
||||
|
||||
template = """
|
||||
TEMPLATE = """
|
||||
def euler_XXX():
|
||||
return 0
|
||||
|
||||
@@ -9,7 +9,8 @@ def euler_XXX():
|
||||
if __name__ == "__main__":
|
||||
solution = euler_XXX()
|
||||
print("eXXX.py: " + str(solution))
|
||||
assert(solution == 0)
|
||||
# assert(solution == 0)
|
||||
|
||||
"""
|
||||
|
||||
|
||||
@@ -20,6 +21,6 @@ for i in range(FROM, TILL + 1):
|
||||
e = str(i)
|
||||
filename = "e" + e + ".py"
|
||||
with open(filename, "w") as f:
|
||||
s = template.replace("XXX", e)
|
||||
s = TEMPLATE.replace("XXX", e)
|
||||
f.write(s)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user