diff --git a/strat/main.py b/strat/main.py index 4729271..6f50d7a 100644 --- a/strat/main.py +++ b/strat/main.py @@ -1,10 +1,14 @@ # Y8O353, E0HJQL -import numpy as np +def avg(ls: list) -> int: + if len(ls) != 0: + return sum(ls) / len(ls) + else: + return 0 -def decision(h1, h2): - if 1 in h2[:4]: +def decision(h1: list, h2: list) -> int: + if avg(h2[:4]) >= 0.05: return 1 else: return 0