


'''simple docstring'''

def _SCREAMING_SNAKE_CASE      (A  , A       )       ->       tuple[float, float]:






       """simple docstring"""







       if not len(A       ) == len(A       ) == 3:
              raise ValueError('''Please enter a valid equation.'''       )
       if equationa[0] == equationa[1] == equationa[0] == equationa[1] == 0:
              raise ValueError('''Both a & b of two equations can\'t be zero.'''       )

       # Extract the coefficients
       lowercase__			,lowercase__			,lowercase__      			= equationa
       lowercase__			,lowercase__			,lowercase__      			= equationa

       # Calculate the determinants of the matrices
       lowercase__      			= aa * ba - aa * ba
       lowercase__      			= ca * ba - ca * ba
       lowercase__      			= aa * ca - aa * ca

       # Check if the system of linear equations has a solution (using Cramer's rule)
       if determinant == 0:
              if determinant_x == determinant_y == 0:
                     raise ValueError('''Infinite solutions. (Consistent system)'''       )
              else:
                     raise ValueError('''No solution. (Inconsistent system)'''       )
       else:
              if determinant_x == determinant_y == 0:
                     # Trivial solution (Inconsistent system)
                     return (0.0, 0.0)
              else:
                     lowercase__      			= determinant_x / determinant
                     lowercase__      			= determinant_y / determinant
                     # Non-Trivial Solution (Consistent system)
                     return (x, y)








'''simple docstring'''

from __future__ import annotations

def _SCREAMING_SNAKE_CASE      (A  , A       )       ->       list[list[int]]:






       """simple docstring"""







       lowercase__      			= []
       create_all_state(1  , A  , A  , []  , A       )
       return result

def _SCREAMING_SNAKE_CASE      (A  , A  , A  , A  , A  , )       ->       None:






       """simple docstring"""







       if level == 0:
              total_list.append(current_list[:]       )
              return

       for i in range(A  , total_number - level + 2       ):
              current_list.append(A       )
              create_all_state(i + 1  , A  , level - 1  , A  , A       )
              current_list.pop()

def _SCREAMING_SNAKE_CASE      (A       )       ->       None:






       """simple docstring"""







       for i in total_list:
              print(*A       )


if __name__ == "__main__":
 lowerCamelCase							:   Tuple  						=	4
 lowerCamelCase							:   Union[str, Any]  						=	2
 lowerCamelCase							:   Dict  						=	generate_all_combinations(n, k)
 print_all_state(total_list)




