For the pythons snippet below,
def line1(self, arr: List[int], a: int, b: int, c: int) -> int:
what does -> int mean? what is the purpose of b:int then? also what does self mean?
For the pythons snippet below,
def line1(self, arr: List[int], a: int, b: int, c: int) -> int:
what does -> int mean? what is the purpose of b:int then? also what does self mean?
Please at least try to use Google. Those are very simple questions.
But anyway:
self - means that a function belongs to a class and with self all the class attributes are passed to function so it could access them
-> - is a relatively new feature in python, it helps with a type annotation, it defines what function will return. In this case, the function is expected to return an integer value.
: - has the same purposes as the "arrow" from above it means that function expects to receive an integer value for a, b and c
You have got yourself some useful links in comments, please go over them.