add functional example