horizontal checking code written