When haloalkane or alkyl halide with a β hydrogen is heated with alcoholic solution of KOH, elimination of a hydrogen atom from β carbon and halogen atom from α-carbon occurs as a result, alkene is formed as product. Since β hydrogen atom is involved in the elimination reaction, it is often called β elimination.
P and Q are respectively.