Show that $X$ is Hausdorff. 
Suppose that $X$ is a space with the property that
  for any point $p \in X$ there is a  map
  $f: X \rightarrow \mathbb{R}$ such that $f^{-1}(1) = \{p\}$.
  Show that $X$ is Hausdorff. 

Solution:
Suppose that $x \neq y$ are points in $X$. Choose
$f: X \rightarrow \mathbb{R}$ with $f(x) = 1$
and $f(y) \neq 1$ and open disjoint intervals
around $1$ and $f(y)$ in $\mathbb{R}$ (which is possible
since $\mathbb{R}$ is Hausdorff). 
Now we are done if we can say that the inverse
images of these intervals under $f$ are open
disjoint sets in $X$ containing $x$ and $y$, respectively.
Because then $X$ is Hausdorff.

$f$ is a map, i.e. a continuous function, and therefore its
inverse takes open sets to open sets.
This is probably a very simple question and bordering on stupid
for you experienced topologists
but i just wonder how we can be sure that the inverse takes
disjoint open sets to disjoint open sets?

It's true for every map that the inverse image of disjoint sets are disjoint sets. 
Let $f\colon X\to Y$ be any map between sets,  $A, B\subseteq Y$, $A\cap B=\emptyset$. Suppose there is an element
$x\in f^{-1}(A)\cap f^{-1}(B)$. Then we have $f(x)\in A\cap B=\emptyset$ a contradiction.
