add terminate end example