A function F(x) when composed in itself number of times is called an iterated function.
Let $F(x)=\frac{1}{1+x}$
$F(\frac{1}{2})=\frac{2}{3}$
$F(\frac{2}{3})=\frac{3}{5}$
$F(\frac{3}{5})=\frac{5}{8}$
Continuing in this way to infinite number of times it turns out that we get $\frac{\sqrt{5}-1}{2}.$
But we see above that we will continue to get rational fractions however long we continue.
So $\frac{\sqrt{5}-1}{2}$ or simply $\sqrt{5}$ is rational.
Are we incorrect in assumption or we haven't defined irrational numbers properly?
Think of a sequence of rational numbers that approximate an irrational number closer and closer:
$$3,\\ 3.1, \\3.14, \\3.141, \\3.1415, \\3.14159, \\3.141592, \\3.1415926,\\\cdots$$
Such a rational sequence converges... to an irrational number.
Intuitively, this is possible because the denominators get larger and larger, and "in the end" the denominator becomes infinite.