#break in Velocity script

Hi,

I need to break the  foreach loop when the condition fails.

Is there an alternative  for#break in velocity script

Ex code

#set($a=[1,2,3,4,5,6,7,8,9])
#foreach($item in $a)
  #if($item==5)
  #break
  #end
$a
#end