Formal:
* J'ai un stylo. (Most common and neutral)
Informal:
* J'ai un stylo. (Still works here)
* J'ai un crayon. (If you are talking about a pencil)
* J'ai un bic. (Slang for ballpoint pen, mostly used in France)
* J'ai un stylo à bille. (More formal way of saying ballpoint pen)
You can also use the verb "avoir" in a more informal way with the phrase "j'en ai un":
* J'en ai un. (I have one, referring to a pen)
The choice of which phrase to use depends on the context and your level of formality.