logical error

logical error substring