Explanation:
# Let our string is brainlycom
Main = "brainlycom"
# First we will print the original string.
print("The original string : " + str(Main))
#Now Reverse Sort a String
Reverse_Sort= ''.join(sorted(Main, reverse=True))
print("String after reverse sorting : " + str(Reverse_Sort))
After running the above code you will get the result:
The original string : brainlycom
String after reverse sorting : yronmlicba