Let’s take an example

Given a line
l
with point P marked on it

With P as center, and any radius,
draw an arc intersecting the line at points A and B
 Now with A as center, and radius more than AP,
draw an arc.
With B as center, and same radius as before, draw an arc
4.Mark the point of intersection of the two arcs as point Q Join P & Q.
∴ PQ is the line perpendicular to line l