string=“something somethig something”
now i want to change /<a.*a>/ to “tag”
i want result like this
string=“something tag somethig tag something”
but when i try
string =~ /<a.*a>/ # here $& —>" somethig "
$`+‘tag’+$’ # ‘something tag something’
how can i change each tag ?
any idea ?