added find connected islands algo