codeforces/552A_table.py
def calculate(self):
        """ Main calcualtion function of the class """
        sum = 0
        for y in range(1, self.N+2):
            for x in range(1, self.N+2):
                for (start, end) in zip(self.starts, self.ends):
                    inside = (
                        x >= start[0] and y >= start[1] and
                        x <= end[0] and y <= end[1])
                    if inside:
                        sum += 1
        return sum
 Main calcualtion function of the class 
Main calcualtion function of the class
Main calcualtion function of the class
def calculate(self):
        sum = 0
        for y in range(1, self.N+2):
            for x in range(1, self.N+2):
                for (start, end) in zip(self.starts, self.ends):
                    inside = (
                        x >= start[0] and y >= start[1] and
                        x <= end[0] and y <= end[1])
                    if inside:
                        sum += 1
        return sum
def calculate ( self ) : sum = 0 for y in range ( 1 , self . N + 2 ) : for x in range ( 1 , self . N + 2 ) : for ( start , end ) in zip ( self . starts , self . ends ) : inside = ( x >= start [ 0 ] and y >= start [ 1 ] and x <= end [ 0 ] and y <= end [ 1 ] ) if inside : sum += 1 return sum
Main calcualtion function of the class
Main calcualtion function of the class
""" Main calcualtion function of the class """
self