Variable Stars in globular clusters and in related systems