





"""simple docstring"""



class 						__snake_case   :





 """simple docstring"""


 def __init__(       self   ,		__lowerCamelCase    ):



     '''simple docstring'''




     __A       :		Union[str, Any]							=	set_counts
     __A       :		Tuple							=	max(__lowerCamelCase    )
     __A       :		List[Any]							=	len(__lowerCamelCase    )
     __A       :		Optional[Any]							=	[1] * num_sets
     __A       :		Optional[int]							=	list(range(__lowerCamelCase    )    )

 def    UpperCamelCase__(       self   ,		__lowerCamelCase   ,		__lowerCamelCase    ):



     '''simple docstring'''




     __A       :		Any							=	self.get_parent(__lowerCamelCase    )
     __A       :		List[str]							=	self.get_parent(__lowerCamelCase    )

     if src_parent == dst_parent:
         return False

     if self.ranks[dst_parent] >= self.ranks[src_parent]:
         self.set_counts[dst_parent] += self.set_counts[src_parent]
         __A       :		Optional[Any]							=	0
         __A       :		str							=	dst_parent
         if self.ranks[dst_parent] == self.ranks[src_parent]:
             self.ranks[dst_parent] += 1
         __A       :		List[Any]							=	self.set_counts[dst_parent]
     else:
         self.set_counts[src_parent] += self.set_counts[dst_parent]
         __A       :		str							=	0
         __A       :		List[Any]							=	src_parent
         __A       :		Tuple							=	self.set_counts[src_parent]

     __A       :		Optional[Any]							=	max(self.max_set   ,		__lowerCamelCase    )
     return True







 def    UpperCamelCase__(       self   ,		__lowerCamelCase    ):



     '''simple docstring'''




     if self.parents[disj_set] == disj_set:
         return disj_set
     __A       :		Tuple							=	self.get_parent(self.parents[disj_set]    )
     return self.parents[disj_set]











"""simple docstring"""



def 						__lowercase	(  snake_case_    :    int = 2000000		)  ->int:



    '''simple docstring'''







    __A       :		List[Any]							=	[0 for i in range(n + 1		)]
    __A       :		str							=	1
    __A       :		Dict							=	1

    for i in range(2							,int(n**0.5		) + 1		):
        if primality_list[i] == 0:
            for j in range(i * i							,n + 1							,snake_case_		):
                __A       :		List[Any]							=	1
    __A       :		Union[str, Any]							=	0
    for i in range(snake_case_		):
        if primality_list[i] == 0:
            sum_of_primes += i
    return sum_of_primes


if __name__ == "__main__":
       print(f'''{solution() = }''')




