Introducing doubly-bonded functional groups

Monovalent groups like OH and Cl replace one hydrogen at a carbon atom of a hydrocarbon chain.
 
Depending on the number of carbon atoms at the carbon-bearing OH (or Cl), alcohols and alkyl halides are classified as either primary, secondary or tertiary.
 
tertiary (3°)secondary (2°)primary (1°)

Double bonds replace two hydrogen atoms
For a carbon-carbon double bond the two hydrogen atoms are on adjacent carbons.
Double bonds can be between any pair of carbon atoms in a chain, provided each carbon atom bears one hydrogen.  The possible alkene isomers for the C5 skeleton above are shown.

A carbon-oxygen double bond replaces two hydrogen atoms from the same carbon atom. 
Thus, carbonyl groups can be at either the end of a chain or in the middle of a chain, but cannot be at branch points (because these carbon atoms have a maximum of one hydrogen atom).
 

ketone
C=O in the chain
aldehyde
C=O at the end of the chain.
A carboxylic acid group () has three bonds from oxygen to carbon and must be at the end of the chain.
 
carboxylic acidcarboxylic acid