Which package is required for \Z to work as the symbol for the set of integers? [duplicate]

This question already has an answer here:

\Z should produce the symbol for the set of integers, but I have not been able to find the package that enables this feature.

I have tried dsfont as well as amsmath,amsfonts,amsthm,amssymb but none of them seem to have it.

-
Can you show the code that you tried to use? –  soandos Feb 22 at 17:59

marked as duplicate by mafp, tohecz, Kurt, T. Verron, Martin SchröderFeb 22 at 18:26

\usepackage{amsfonts}
\newcommand{\Z}{\mathbb{Z}}


and then using it in equations?

EDIT: forgot, that it needs amsfonts package.

-
I actually ended up doing that just now, but I still wonder whether there's a package that predefines them. –  merlin2011 Feb 22 at 17:52
@merlin2011 If there is such, it is definitely not a good one. For me, \Z refers to \mathcal{Z} as I don't work with integers, but I do work with a "zero machine" called this way. Predefining shortcuts like this if you don't use them is a bad idea. Define only such symbols you really use. –  tohecz Feb 22 at 18:06
Either amsfonts or amssymb; the latter loads the former, and is usually recommended. –  egreg Feb 22 at 18:19