Perl Regular Express is good for this kind of question.

data HAVE;
infile datalines truncover;
input STR $100.;
datalines;
Some strings
have unwanted sub
strings in them

A s
entence must not be cont
aminated with unwanted subs
trings
Several line
breaks
are inserted here

Resulting st
ring must be n
eat and f
ree from un
desirable substrings
Ugly unwanted substrings

must
be
removed

Let's remove them
using S
A
S language
Ex
periment is a
bout to b
egin

Simpli
city may sur
prise you

;
data want;
set have;
want=prxchange('s/<.+?>//',-1,str);
run;