Complex Redirect Rule

I'm not sure if this topic exist and I'm not sure if this is possible to create 1 rule and applies to all. What I'm trying to do is. I have so many different urls but usually they have the same end and I want the last end which is "all" to be remove on new/redirect url. for example