str trim(str s)
import String;
rascal>import String; ok rascal>trim(" jelly >>>>>>>beans "); str: "jelly\nbeans"