
from __future__ import annotations

from typing import Any






class 							SCREAMING_SNAKE_CASE__     :

							"""simple docstring"""






							def __init__(	self  ,						SCREAMING_SNAKE_CASE_  ,						SCREAMING_SNAKE_CASE_      )-> None:  # noqa: A002





													'''simple docstring'''






													__UpperCamelCase  	=      item
													__UpperCamelCase  	=      next






class 							SCREAMING_SNAKE_CASE__     :

							"""simple docstring"""






							def __init__(	self      )-> None:





													'''simple docstring'''






													__UpperCamelCase  	=      None
													__UpperCamelCase  	=      0



							def      A__		(	self  ,						SCREAMING_SNAKE_CASE_      )-> None:





													'''simple docstring'''






													__UpperCamelCase  	=      Node(SCREAMING_SNAKE_CASE_  ,						self.head      )
													self.size += 1



							def      A__		(	self      )-> Any:





													'''simple docstring'''






													if self.head is None:
																			return None
													else:
																			__UpperCamelCase  	=      self.head.item
																			__UpperCamelCase  	=      self.head.next
																			self.size -= 1
																			return item



							def      A__		(	self      )-> bool:





													'''simple docstring'''






													return self.head is None



							def __str__(	self      )-> str:





													'''simple docstring'''






													if self.is_empty():
																			return ""
													else:
																			__UpperCamelCase  	=      self.head
																			__UpperCamelCase  	=      ''''''
																			__UpperCamelCase  	=      []
																			while iterate:
																									item_list.append(str(iterate.item      )      )
																									__UpperCamelCase  	=      iterate.next

																			__UpperCamelCase  	=      ''' --> '''.join(SCREAMING_SNAKE_CASE_      )

																			return item_str



							def __len__(	self      )-> int:





													'''simple docstring'''






													return self.size






from __future__ import annotations




def 		A						(  SCREAMING_SNAKE_CASE     ,						SCREAMING_SNAKE_CASE     ,						SCREAMING_SNAKE_CASE     ,						):




			"""simple docstring"""


			if not all((nth_term, start_term_a, common_ratio_r)							):
						return []
			UpperCAmelCase__		:list[float | int] 		=    []
			UpperCAmelCase__		:str 		=    1
			UpperCAmelCase__		:Any 		=    common_ratio_r
			for _ in range(int(SCREAMING_SNAKE_CASE							)							):
						if not series:
									series.append(SCREAMING_SNAKE_CASE							)
						else:
									power += 1
									series.append(float(start_term_a * multiple							)							)
									UpperCAmelCase__		:str 		=    pow(float(SCREAMING_SNAKE_CASE							)     ,						SCREAMING_SNAKE_CASE							)
			return series


if __name__ == "__main__":
						import doctest

						doctest.testmod()

						__snake_case					:							Optional[int]           =							float(input('Enter the last number (n term) of the Geometric Series'))
						__snake_case					:							List[str]           =							float(input('Enter the starting term (a) of the Geometric Series'))
						__snake_case					:							Optional[int]           =							float(
						    input('Enter the common ratio between two terms (r) of the Geometric Series')
						)
						print('Formula of Geometric Series => a + ar + ar^2 ... +ar^n')
						print(geometric_series(nth_term, start_term_a, common_ratio_r))





