Limit of a function whose values depend on $x$ being odd or even I couldn't find an answer through google or here, so i hope this isn't a duplicate.
Let $f(x)$ be given by:
$$
f(x) = \begin{cases}
       x & : x=2n\\
       1/x & : x=2n+1
   \end{cases}
$$
Find $\lim_{x \to \infty} f(x).$  
The limit is different depending on $x$ being odd or even. So what's the limit of $f(x)$?
Attempt: this limit doesn't exist because we have different values for $x \to \infty$ which could be either odd or even. My doubt is $\infty$ can't be both even and odd at the same time so one should apply.
So what do you ladies/gents think?
Also, when confronted with functions like these and one needs to know the limit to gain more information about the behavior of $f(x)$, how should the problem be attacked?
 A: Your first statement following the word "attempt" has the correct intuition: "this limit doesn't exist because we have different values for" ... $\lim_{x\to \infty} f(x) $, which depends on x "which could be either odd or even." (So I'm assuming we are taking $x$ to be an integer, since the property of being "odd" or "even" must entail $x \in \mathbb{Z}$). 
The subsequent doubt you express originates from the erroneous conclusion that $\infty$ must be even or odd. It is neither. $\infty$ is not a number, not in the sense of it being odd or even, and not in the sense that we can evaluate $f(\infty)$! (We do not evaluate the $\lim_{x \to \infty} f(x)$ AT infinity, only as $x$ approaches infinity.)
When taking the limit of $f(x)$ as $x \to \infty$, we look at what happens as $x$ approaches infinity, and as you observe, $x$ oscillates between odd and even values, so as $x \to \infty$, $f(x)$, as defined, also oscillates: at extremely large $x$, $f(x)$ oscillates between extremely large values and extremely small values (approaching $\infty$ when $x$ is even, and approaching zero when $x$ is odd. 
Hence the limit does not exist.

Note: when $x$ goes to some finite number, say $a$, you may be tempted to simply "plug it in" to $f(x)$ when evaluating $\lim_{x\to a}f(x)$. You should be careful, though. This only works when $f(x)$ is continuous at that point $a$.  Limits are really only about what happens as $x$ approaches an x-value, or infinity, not what $f(x)$ actually is at that value. This is an important to remember.
