Is there any alternative for this
Yes: $ans =~ s/[[:space:][:cntrl:]]//g;
In reply to Re^3: Strip filename by almut in thread Strip filename by kalyanrajsista