Probability of logging into a system that blocks you out after 3 attempts. I've ran into this tricky problem I can't seem to solve:

Suppose there are $n$ passwords, where only one allows you to log into a system. If the system blocks you out after 3 attempts, what is the probability of logging in?

The problem asks for the particular case when $n=10$, but I suppose this doesn't change much.

What I've tried: 
Let $A_i=\text{The $i$-th key is the correct one.}$ Then $P(\text{Log in})=P(\bigcup A_i)$, $i=1,2,3$.
This yields (as the $A_i$ should be mutually exclusive) that the probability of logging in is $\frac {1}{n}+\frac {1}{n-1}+\frac {1}{n-2}$ but I know this is incorrect.
Why is my attempt wrong, and how do you solve this?
 A: You are almost correct:$$\Pr(\text{Login})=\Pr(\bigcup_{i=1}^3 A_i)=\sum_{i=1}^3\Pr(A_i)=\frac1{n}+\frac1{n}+\frac1{n}=\frac3{n}$$
We are dealing with disjoint equiprobable events. The probability that e.g the second key is the correct one is not smaller than the probability that the first key is the correct one.

edit:
In your try you actually calculate something else:$$\Pr(A_1)+\Pr(A_2\mid A_1^c)+\Pr(A_3\mid A_1^c\cup A_2^c)$$
which can be looked at as a senseless expression.
A: Calculate $1$ minus the probability of the complementary event.
The complementary event is the event of failing to log in within $3$ attempts.
The total number of ways to choose $3$ different passwords is $\binom{n}{3}$.
The number of ways to choose $3$ different and incorrect passwords is $\binom{n-1}{3}$.
So the probability of failing to log in within $3$ attempts is $\frac{\binom{n-1}{3}}{\binom{n}{3}}=\frac{n-3}{n}$.
Hence the probability to log in within $3$ attempts is $1-\frac{n-3}{n}=\frac{3}{n}$.
A: We can think like the following too (with conditional probabilities):
$Pr(Login) = Pr(A_1) + Pr(A_1^c \cap A_2) + Pr(A_1^c \cap A_2^c \cap A_3)$
$=Pr(A_1) + Pr(A_1^c)Pr(A_2|A_1^c) + Pr(A_1^c)Pr(A_2^c|A_1^c)Pr(A_3|A_1^cA_2^c)$, by chain rule
$=\frac{1}{n}+\frac{n-1}{n}.\frac{1}{n-1}+\frac{n-1}{n}.\frac{n-2}{n-1}.\frac{1}{n-2}=\frac{3}{n}$ 
