

import math
def 		UpperCamelCase_(     snake_case__:    int  )			->					List[Any]:
 UpperCAmelCase__     							=							0
 UpperCAmelCase__     							=							0
 while num > 0:
  UpperCAmelCase__     							=							num % 8
  UpperCAmelCase__     							=							octal + (remainder * math.floor(math.pow(10    ,       lowercase_  )  ))
  counter += 1
  UpperCAmelCase__     							=							math.floor(num / 8  )  # basically /= 8 without remainder if any
  # This formatting removes trailing '.0' from `octal`.
 return f"0o{int(lowercase_  )}"
def 		UpperCamelCase_(     )			->					List[str]:
 print('\n2 in octal is:'  )
 print(decimal_to_octal(2  )  )  # = 2
 print('\n8 in octal is:'  )
 print(decimal_to_octal(8  )  )  # = 10
 print('\n65 in octal is:'  )
 print(decimal_to_octal(65  )  )  # = 101
 print('\n216 in octal is:'  )
 print(decimal_to_octal(2_16  )  )  # = 330
 print('\n512 in octal is:'  )
 print(decimal_to_octal(5_12  )  )  # = 1000
 print('\n'  )


if __name__ == "__main__":
 main()











'''simple docstring'''







from __future__ import annotations

from collections.abc import Iterator
from typing import Generic, TypeVar

__lowerCAmelCase        =							TypeVar("T")




class   __SCREAMING_SNAKE_CASE       (Generic[T]       ):


  """simple docstring"""


  def __init__(			self   ,	UpperCamelCase__	):






         """simple docstring"""


         a_						     =			data
         a_						     =			None







  def __str__(			self	):






         """simple docstring"""


         return f'{self.data}'





class   __SCREAMING_SNAKE_CASE       (Generic[T]       ):


  """simple docstring"""


  def __init__(			self	):






         """simple docstring"""


         a_						     =			None







  def __iter__(			self	):






         """simple docstring"""


         a_						     =			self.top
         while node:
                yield node.data
                a_						     =			node.next







  def __str__(			self	):






         """simple docstring"""


         return "->".join([str(UpperCamelCase__	) for item in self]	)







  def __len__(			self	):






         """simple docstring"""


         return len(tuple(iter(self	)	)	)







  def    _a       (			self	):






         """simple docstring"""


         return self.top is None







  def    _a       (			self   ,	UpperCamelCase__	):






         """simple docstring"""


         a_						     =			Node(UpperCamelCase__	)
         if not self.is_empty():
                a_						     =			self.top
         a_						     =			node







  def    _a       (			self	):






         """simple docstring"""


         if self.is_empty():
                raise IndexError('pop from empty stack'	)
         assert isinstance(self.top   ,	UpperCamelCase__	)
         a_						     =			self.top
         a_						     =			self.top.next
         return pop_node.data







  def    _a       (			self	):






         """simple docstring"""


         if self.is_empty():
                raise IndexError('peek from empty stack'	)

         assert self.top is not None
         return self.top.data







  def    _a       (			self	):






         """simple docstring"""


         a_						     =			None


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

  testmod()




