Sex when pregnant

Can you have sex when you are pregnant??