


'''simple docstring'''





def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: list[int] ):






			"""simple docstring"""




			__A=	[]
			if len(_SCREAMING_SNAKE_CASE ) == 1:
						return [nums.copy()]
			for _ in range(len(_SCREAMING_SNAKE_CASE ) ):
						__A=	nums.pop(0 )
						__A=	permute(_SCREAMING_SNAKE_CASE )
						for perm in permutations:
									perm.append(_SCREAMING_SNAKE_CASE )
						result.extend(_SCREAMING_SNAKE_CASE )
						nums.append(_SCREAMING_SNAKE_CASE )
			return result






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: int ):






			"""simple docstring"""




			def backtrack(_SCREAMING_SNAKE_CASE					: str ):
						if start == len(_SCREAMING_SNAKE_CASE ) - 1:
									output.append(nums[:] )
						else:
									for i in range(_SCREAMING_SNAKE_CASE,len(_SCREAMING_SNAKE_CASE ) ):
												__A,	__A=	nums[i], nums[start]
												backtrack(start + 1 )
												__A,	__A=	nums[i], nums[start]  # backtrack

			__A=	[]
			backtrack(0 )
			return output


if __name__ == "__main__":
					import doctest

					# use res to print the data in permute2 function
					UpperCAmelCase__  			=				permutea([1, 2, 3])
					print(res)
					doctest.testmod()







'''simple docstring'''





def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: int,_SCREAMING_SNAKE_CASE					: int ):






			"""simple docstring"""




			return int((input_a, input_a).count(1 ) != 0 )






def 						UpperCAmelCase__(				):






			"""simple docstring"""




			assert or_gate(0,0 ) == 0
			assert or_gate(0,1 ) == 1
			assert or_gate(1,0 ) == 1
			assert or_gate(1,1 ) == 1


if __name__ == "__main__":
					print(or_gate(0, 1))
					print(or_gate(1, 0))
					print(or_gate(0, 0))
					print(or_gate(1, 1))



