


"""simple docstring"""


def _lowerCamelCase			(	_UpperCamelCase					,				_UpperCamelCase   ):

			'''simple docstring'''




			__lowerCAmelCase       					=    [[] for _ in range(_UpperCamelCase   )]
			__lowerCAmelCase       					=    key - 1

			if key <= 0:
						raise ValueError("Height of grid can't be 0 or negative"   )
			if key == 1 or len(_UpperCamelCase   ) <= key:
						return input_string

			for position, character in enumerate(_UpperCamelCase   ):
						__lowerCAmelCase       					=    position % (lowest * 2)  # puts it in bounds
						__lowerCAmelCase       					=    min(_UpperCamelCase					,				lowest * 2 - num   )  # creates zigzag pattern
						temp_grid[num].append(_UpperCamelCase   )
			__lowerCAmelCase       					=    ["".join(_UpperCamelCase   ) for row in temp_grid]
			__lowerCAmelCase       					=    "".join(_UpperCamelCase   )

			return output_string


def _lowerCamelCase			(	_UpperCamelCase					,				_UpperCamelCase   ):

			'''simple docstring'''




			__lowerCAmelCase       					=    []
			__lowerCAmelCase       					=    key - 1

			if key <= 0:
						raise ValueError("Height of grid can't be 0 or negative"   )
			if key == 1:
						return input_string

			__lowerCAmelCase       					=    [[] for _ in range(_UpperCamelCase   )]  # generates template
			for position in range(len(_UpperCamelCase   )   ):
						__lowerCAmelCase       					=    position % (lowest * 2)  # puts it in bounds
						__lowerCAmelCase       					=    min(_UpperCamelCase					,				lowest * 2 - num   )  # creates zigzag pattern
						temp_grid[num].append("*"   )

			__lowerCAmelCase       					=    0
			for row in temp_grid:  # fills in the characters
						__lowerCAmelCase       					=    input_string[counter : counter + len(_UpperCamelCase   )]
						grid.append(list(_UpperCamelCase   )   )
						counter += len(_UpperCamelCase   )

			__lowerCAmelCase       					=    ""  # reads as zigzag
			for position in range(len(_UpperCamelCase   )   ):
						__lowerCAmelCase       					=    position % (lowest * 2)  # puts it in bounds
						__lowerCAmelCase       					=    min(_UpperCamelCase					,				lowest * 2 - num   )  # creates zigzag pattern
						output_string += grid[num][0]
						grid[num].pop(0   )
			return output_string


def _lowerCamelCase			(	_UpperCamelCase   ):

			'''simple docstring'''




			__lowerCAmelCase       					=    {}
			for key_guess in range(1					,				len(_UpperCamelCase   )   ):  # tries every key
						__lowerCAmelCase       					=    decrypt(_UpperCamelCase					,				_UpperCamelCase   )
			return results


if __name__ == "__main__":
	import doctest

	doctest.testmod()









"""simple docstring"""


import cmath
import math


def _lowerCamelCase			(	_UpperCamelCase					,				_UpperCamelCase					,				_UpperCamelCase					,				_UpperCamelCase   ):

			'''simple docstring'''




			__lowerCAmelCase       					=    math.radians(_UpperCamelCase   )
			__lowerCAmelCase       					=    math.radians(_UpperCamelCase   )

			# Convert voltage and current to rectangular form
			__lowerCAmelCase       					=    cmath.rect(_UpperCamelCase					,				_UpperCamelCase   )
			__lowerCAmelCase       					=    cmath.rect(_UpperCamelCase					,				_UpperCamelCase   )

			# Calculate apparent power
			return voltage_rect * current_rect


if __name__ == "__main__":
	import doctest

	doctest.testmod()




