


'''simple docstring'''



def 			UpperCAmelCase__					(	UpperCAmelCase_    :				int							)     ->		list[int]:

     if length <= 0 or not isinstance(UpperCAmelCase_      ,    UpperCAmelCase_							):
          raise ValueError('Length must be a positive integer.'							)
     return [n * (2 * n - 1) for n in range(UpperCAmelCase_							)]


if __name__ == "__main__":
      print(hexagonal_numbers(length=5))
      print(hexagonal_numbers(length=10))










'''simple docstring'''



A__		:					Any												=  8.3_1_4_4_6_2  # Unit - J mol-1 K-1



def 			UpperCAmelCase__					(	UpperCAmelCase_    :				float      ,    UpperCAmelCase_    :				float      ,    UpperCAmelCase_    :				float							)     ->		float:
     if moles < 0 or kelvin < 0 or volume < 0:
          raise ValueError('Invalid inputs. Enter positive value.'							)
     return moles * kelvin * UNIVERSAL_GAS_CONSTANT / volume



def 			UpperCAmelCase__					(	UpperCAmelCase_    :				float      ,    UpperCAmelCase_    :				float      ,    UpperCAmelCase_    :				float							)     ->		float:
     if moles < 0 or kelvin < 0 or pressure < 0:
          raise ValueError('Invalid inputs. Enter positive value.'							)
     return moles * kelvin * UNIVERSAL_GAS_CONSTANT / pressure


if __name__ == "__main__":
      from doctest import testmod

      testmod()






