move everything into a submodule to avoid namespace collisions
This commit is contained in:
parent
63dc8da100
commit
5c811280d7
0
tools/__init__.py
Normal file
0
tools/__init__.py
Normal file
@ -1,8 +1,8 @@
|
|||||||
import os
|
import os
|
||||||
import tools
|
|
||||||
from typing import List, Any, Type, Union
|
from typing import List, Any, Type, Union
|
||||||
|
from .tools import get_script_dir
|
||||||
|
|
||||||
BASE_PATH = tools.get_script_dir()
|
BASE_PATH = get_script_dir()
|
||||||
INPUTS_PATH = os.path.join(BASE_PATH, 'inputs')
|
INPUTS_PATH = os.path.join(BASE_PATH, 'inputs')
|
||||||
|
|
||||||
|
|
||||||
5
tools/int_seq.py
Normal file
5
tools/int_seq.py
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
def triangular(n: int) -> int:
|
||||||
|
"""
|
||||||
|
0, 1, 3, 6, 10, 15, ...
|
||||||
|
"""
|
||||||
|
return int(n * (n + 1) / 2)
|
||||||
Loading…
Reference in New Issue
Block a user