Added avg query
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
from abc import ABC, abstractmethod
|
||||
from typing import Optional, Callable
|
||||
from typing import Optional, Callable, Union
|
||||
|
||||
|
||||
class IterableABC(ABC, list):
|
||||
@@ -14,6 +14,9 @@ class IterableABC(ABC, list):
|
||||
@abstractmethod
|
||||
def all(self, func: Callable) -> bool: pass
|
||||
|
||||
@abstractmethod
|
||||
def average(self, t: type, func: Callable) -> Union[int, float, complex]: pass
|
||||
|
||||
@abstractmethod
|
||||
def first(self) -> any: pass
|
||||
|
||||
|
Reference in New Issue
Block a user