def   lowerCAmelCase_ (				__lowerCAmelCase = 10_00						)->  int:






      '''simple docstring'''





      UpperCAmelCase    : Tuple      =[0, 3, 3, 5, 4, 4, 3, 5, 5, 4, 3, 6, 6, 8, 8, 7, 7, 9, 8, 8]
      # number of letters in twenty, thirty, ..., ninety (0 for numbers less than
      # 20 due to inconsistency in teens)
      UpperCAmelCase    : Dict      =[0, 0, 6, 6, 5, 5, 5, 7, 6, 6]

      UpperCAmelCase    : Optional[Any]      =0

      for i in range(1		,					n + 1						):
            if i < 10_00:
                  if i >= 1_00:
                        # add number of letters for "n hundred"
                        count += ones_counts[i // 1_00] + 7

                        if i % 1_00 != 0:
                              # add number of letters for "and" if number is not multiple
                              # of 100
                              count += 3

                  if 0 < i % 1_00 < 20:
                        # add number of letters for one, two, three, ..., nineteen
                        # (could be combined with below if not for inconsistency in
                        # teens)
                        count += ones_counts[i % 1_00]
                  else:
                        # add number of letters for twenty, twenty one, ..., ninety
                        # nine
                        count += ones_counts[i % 10]
                        count += tens_counts[(i % 1_00 - i % 10) // 10]
            else:
                  count += ones_counts[i // 10_00] + 8
      return count


if __name__ == "__main__":
     print(solution(int(input().strip())))

__snake_case			      =    [[0, 1, 1], [0, 0, 1], [1, 0, 0]]







class 			__snake_case   :
 def __init__(  self		,   snake_case__						)	->							Any:
       '''simple docstring'''





       UpperCAmelCase    : List[Any]      =name
       UpperCAmelCase    : Tuple      =[]
       UpperCAmelCase    : str      =[]
 def 	UpperCAmelCase__       (  self		,   snake_case__						)	->							int:
       '''simple docstring'''





       self.inbound.append(snake_case__						)
 def 	UpperCAmelCase__       (  self		,   snake_case__						)	->							Dict:
       '''simple docstring'''





       self.outbound.append(snake_case__						)






 def __repr__(  self						)	->							Union[str, Any]:
       '''simple docstring'''





       return f'''<node={self.name} inbound={self.inbound} outbound={self.outbound}>'''





def   lowerCAmelCase_ (				__lowerCAmelCase		,					__lowerCAmelCase=3		,					__lowerCAmelCase=0.85						)->  Any:






      '''simple docstring'''





      UpperCAmelCase    : List[Any]      ={}
      for node in nodes:
            UpperCAmelCase    : str      =1

      UpperCAmelCase    : str      ={}
      for node in nodes:
            UpperCAmelCase    : int      =len(node.outbound						)

      for i in range(__lowerCAmelCase						):
            print(f'''======= Iteration {i + 1} ======='''						)
            for _, node in enumerate(__lowerCAmelCase						):
                  UpperCAmelCase    : Optional[int]      =(1 - d) + d * sum(
                      ranks[ib] / outbounds[ib] for ib in node.inbound						)
            print(__lowerCAmelCase						)





def   lowerCAmelCase_ (				)->  Union[str, Any]:






      '''simple docstring'''





      UpperCAmelCase    : Union[str, Any]      =list(input('''Enter Names of the Nodes: '''						).split()						)

      UpperCAmelCase    : str      =[Node(__lowerCAmelCase						) for name in names]

      for ri, row in enumerate(__lowerCAmelCase						):
            for ci, col in enumerate(__lowerCAmelCase						):
                  if col == 1:
                        nodes[ci].add_inbound(names[ri]						)
                        nodes[ri].add_outbound(names[ci]						)

      print('''======= Nodes ======='''						)
      for node in nodes:
            print(__lowerCAmelCase						)

      page_rank(__lowerCAmelCase						)


if __name__ == "__main__":
     main()
