Create a PHP script to generate all permutations of a given string.
MediumProblem Statement
Create a PHP script to generate all permutations of a given string.
Sample Input
"abc"
Sample Output
["abc","acb","bac","bca","cba","cab"]
Limits
Time: 2s · Memory: 256 MB