The number of atoms in a molecule varies depending on the specific molecule formed. As a rule of thumb, a molecule must be composed of at least two atoms with no maximum amount of atoms as long as all the atoms in the molecule are bonded together somehow.
The atoms that make up a molecule can be of the same element or different types. Diatomic molecules are a specific class of molecules that consist of two molecules of the same element. If the molecule is composed of atoms of at least two different elements, it is a chemical compound. Typically, molecules are bonded together through covalent bonding, in which the atoms bonded together share electrons. Ionic compounds, in which the atoms are exchange electrons and are bonded together by electrical charge and attraction, are not usually considered molecules in chemistry.
Molecules can have several types of properties and classifications based on the atoms and elements present. Carbon- and hydrogen-containing molecules are referred to as organic compounds. Compounds formed out of elements that have a significant difference in their electronegativity values are polar molecules. Macromolecules are biologically important large molecules comprised of several atoms with some containing more than 100 atoms.