Added first rule of adjacency in prolog.