Python program to demonstrate flocking algorithm