Checking for a isosceles triangle