An idiom is a word or phrase which means something different from its literal meaning. Idioms are common phrases or terms whose meaning is changed, but can be understood by their popular use.
Because idioms can mean something different from what the words mean it is difficult for someone not very good at speaking the language to use them properly. Some idioms are only used by some groups of people or at certain times. The idiom shape up or ship out, which is like saying improve your behavior or leave if you don’t, might be said by an employer or supervisor to an employee, but not to other people.