The solution to the compound inequality is all the values of x in which x is either less than 2 or x is greater than 5. This is shown graphically by putting the graphs of the two inequalities together on the same number line.