How to scramble a string of text?
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
Input = "abcdef" And Output = "fdbace"
Steps: "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
string-manipulation
add a comment |Â
up vote
1
down vote
favorite
Input = "abcdef" And Output = "fdbace"
Steps: "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
string-manipulation
2
What, precisely, is the question?
â bbgodfrey
2 hours ago
Reverse the first two letter of the string "abcdef" which will give "bacdef". Then take this as the new string and reverse the first 3 letter. Similarly, proceed for all the characters of the string.
â Bignya ranjan Pathi
2 hours ago
Please edit the comment into the question.
â corey979
1 hour ago
4
OK, I gotta say this: are you seriously asking this place to solve Pancake Scramble? To submit other people's solutions?
â J. M. is somewhat okay.â¦
1 hour ago
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
Input = "abcdef" And Output = "fdbace"
Steps: "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
string-manipulation
Input = "abcdef" And Output = "fdbace"
Steps: "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
string-manipulation
string-manipulation
asked 2 hours ago
Bignya ranjan Pathi
745
745
2
What, precisely, is the question?
â bbgodfrey
2 hours ago
Reverse the first two letter of the string "abcdef" which will give "bacdef". Then take this as the new string and reverse the first 3 letter. Similarly, proceed for all the characters of the string.
â Bignya ranjan Pathi
2 hours ago
Please edit the comment into the question.
â corey979
1 hour ago
4
OK, I gotta say this: are you seriously asking this place to solve Pancake Scramble? To submit other people's solutions?
â J. M. is somewhat okay.â¦
1 hour ago
add a comment |Â
2
What, precisely, is the question?
â bbgodfrey
2 hours ago
Reverse the first two letter of the string "abcdef" which will give "bacdef". Then take this as the new string and reverse the first 3 letter. Similarly, proceed for all the characters of the string.
â Bignya ranjan Pathi
2 hours ago
Please edit the comment into the question.
â corey979
1 hour ago
4
OK, I gotta say this: are you seriously asking this place to solve Pancake Scramble? To submit other people's solutions?
â J. M. is somewhat okay.â¦
1 hour ago
2
2
What, precisely, is the question?
â bbgodfrey
2 hours ago
What, precisely, is the question?
â bbgodfrey
2 hours ago
Reverse the first two letter of the string "abcdef" which will give "bacdef". Then take this as the new string and reverse the first 3 letter. Similarly, proceed for all the characters of the string.
â Bignya ranjan Pathi
2 hours ago
Reverse the first two letter of the string "abcdef" which will give "bacdef". Then take this as the new string and reverse the first 3 letter. Similarly, proceed for all the characters of the string.
â Bignya ranjan Pathi
2 hours ago
Please edit the comment into the question.
â corey979
1 hour ago
Please edit the comment into the question.
â corey979
1 hour ago
4
4
OK, I gotta say this: are you seriously asking this place to solve Pancake Scramble? To submit other people's solutions?
â J. M. is somewhat okay.â¦
1 hour ago
OK, I gotta say this: are you seriously asking this place to solve Pancake Scramble? To submit other people's solutions?
â J. M. is somewhat okay.â¦
1 hour ago
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
4
down vote
accepted
FoldList[
StringJoin[StringReverse[StringTake[#1, 1, #2]], StringTake[#1, #2 + 1 ;;]] &,
"abcdef",
Range[2, 6]
]
"abcdef", "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
4
down vote
accepted
FoldList[
StringJoin[StringReverse[StringTake[#1, 1, #2]], StringTake[#1, #2 + 1 ;;]] &,
"abcdef",
Range[2, 6]
]
"abcdef", "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
add a comment |Â
up vote
4
down vote
accepted
FoldList[
StringJoin[StringReverse[StringTake[#1, 1, #2]], StringTake[#1, #2 + 1 ;;]] &,
"abcdef",
Range[2, 6]
]
"abcdef", "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
add a comment |Â
up vote
4
down vote
accepted
up vote
4
down vote
accepted
FoldList[
StringJoin[StringReverse[StringTake[#1, 1, #2]], StringTake[#1, #2 + 1 ;;]] &,
"abcdef",
Range[2, 6]
]
"abcdef", "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
FoldList[
StringJoin[StringReverse[StringTake[#1, 1, #2]], StringTake[#1, #2 + 1 ;;]] &,
"abcdef",
Range[2, 6]
]
"abcdef", "bacdef", "cabdef", "dbacef", "ecabdf", "fdbace"
answered 2 hours ago
Henrik Schumacher
40.2k255120
40.2k255120
add a comment |Â
add a comment |Â
Â
draft saved
draft discarded
Â
draft saved
draft discarded
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmathematica.stackexchange.com%2fquestions%2f182894%2fhow-to-scramble-a-string-of-text%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
2
What, precisely, is the question?
â bbgodfrey
2 hours ago
Reverse the first two letter of the string "abcdef" which will give "bacdef". Then take this as the new string and reverse the first 3 letter. Similarly, proceed for all the characters of the string.
â Bignya ranjan Pathi
2 hours ago
Please edit the comment into the question.
â corey979
1 hour ago
4
OK, I gotta say this: are you seriously asking this place to solve Pancake Scramble? To submit other people's solutions?
â J. M. is somewhat okay.â¦
1 hour ago