yaworsw/euler-manager

View on GitHub
data/problems/230.yml

Summary

Maintainability
Test Coverage
---
:id: 230
:name: Fibonacci Words
:url: https://projecteuler.net/problem=230
:content: "For any two strings of digits, A and B, we define F<sub>A,B</sub> to be
  the sequence (A,B,AB,BAB,ABBAB,...) in which each term is the concatenation of the
  previous two.\n\nFurther, we define D<sub>A,B</sub>(<var>n</var>) to be the <var>n</var><sup>th</sup>
  digit in the first term of F<sub>A,B</sub> that contains at least <var>n</var> digits.\n\nExample:\n\nLet
  A=1415926535, B=8979323846. We wish to find D<sub>A,B</sub>(35), say.\n\nThe first
  few terms of F<sub>A,B</sub> are:  \n1415926535  \n8979323846  \n14159265358979323846
  \ \n897932384614159265358979323846  \n1415926535897932384689793238461415 **9** 265358979323846\n\nThen
  D<sub>A,B</sub>(35) is the 35<sup>th</sup> digit in the fifth term, which is 9.\n\nNow
  we use for A the first 100 digits of π behind the decimal point:\n\n14159265358979323846264338327950288419716939937510
  \  \n58209749445923078164062862089986280348253421170679\n\nand for B the next hundred
  digits:\n\n82148086513282306647093844609550582231725359408128   \n48111745028410270193852110555964462294895493038196
  .\n\nFind ∑<sub><var>n</var> = 0,1,...,17</sub> &nbsp; 10<sup><var>n</var></sup>×
  D<sub>A,B</sub>((127+19<var>n</var>)×7<sup><var>n</var></sup>) .\n\n"