read to read a path from a user like so:
read -p "Input the file name: " FilePath
The user now enters this string:
What can I do to replace
/. The result I want is:
By the way, the command:
outputs the result:
I have no idea what's wrong with it.