TITLE: If it takes infinite steps to prove a statement, is that a valid proof?
QUESTION [21 upvotes]: In Cantor's diagonal argument, it takes (countable) infinite steps to construct a number that is different from any numbers in a countable infinite sequence, so in fact the proof takes infinite steps too. Is that a valid proof?

REPLY [2 votes]: Since you have a computability bent, here is another version of Cantor's theorem:
Let $T$ be a Turing machine that prints a sequence of outputs. Each of the outputs of $T$ is the specification of a Turing machine that prints a sequence of numbers.
Cantor's argument says there exists a Turing machine $S$ that prints a sequence of numbers that is not printed by any of the outputs of $T$: specifically the Turing machine:

For every natural number $n$:

Simulate $T$ to obtain it's $n$-th output.
If $T$ has halted prematurely:

Output 0
Halt.

Let $M$ be the $n$-th output of $T$.
Simulate $M$ to obtain it's $n$-th output.
If $M$ has halted:

Output 0.

Else

Let $x$ be the $n$-th output of $M$.
Output $x+1$



Furthermore, it's not hard to see there exists a Turing machine that can, given the specification of any $T$ satisfying the hypothesis, will output the specification of the corresponding Turing machine $S$.