What is the average rational number?

Depending on how you order the rationals to begin with, the sequence $x_n$ could tend to anything in $[0,1]$ or could diverge.

Say $y\in[0,1]$. Start with an enumeration $r_1,\dots$ of the rationals in $(0,1)$. When I say "choose a rational such that [whatever]" I mean you should choose the first rational currently on that list that satisfies [whatever], and then cross it off the list.

Start by choosing $10$ rationals in $I_1=(y-1/10,y+1/10)$. Then choose one rational in $[0,1]\setminus I_1$. Then choose $100$ rationals in $I_2=(y-1/100,y+1/100)$, and then choose one rational in $[0,1]\setminus I_2$. Etc.

First, note we have in fact defined a reordering of the original list. No rational appears in the new ordering more than once, because it is crossed off the original list the first time it is chosen. And every rational appears on the new list. In fact you can show by induction on $n$ that $r_n$ must be chosen at some stage: By induction you can assume that every $r_j$ for $j<n$ is chosen at some stage. So at some stage $r_n$ is the first remaining entry on the original list; hence it will be chosen soon, since either it's in $I_k$ or not.

And for large $n$ the vast majority of the rationals in the first $n$ elements of the new ordering are very close to $y$, hence $x_n\to y$.

(Similarly, to get $x_n$ to diverge: Start with a large number of rationals near $0$. Follow with a huge number of rationals near $1$, then a stupendous number of rationals near $0$...)


It depends on the order that you put them.
For example, let $A=(0,1/10]$, $B=(1/10,2/10]$ and $C=(2/10,1)$.
Pick one number from $A$, one from $B$, one from $C$ and repeat. The average will be less than $(\frac1{10}+\frac2{10}+1)/3=13/30$.