I just realized that the question does not have quotes around s/[ABC] [abc]/xx/ so it returns error "sed: -e expression #1, char 7: unterminated `s' command", which means the question currently has an error.
Running the command without quotes or a space returns "ABxxbc", so I don't know which one is correct.
[[email protected] ~]# echo "ABCabc" | sed s/[ABC][abc]/xx/ <--- no space, no quotes
ABxxbc
[[email protected] ~]# echo "ABCabc" | sed s/[ABC] [abc]/xx/ <--- with space, no quotes
sed: -e expression #1, char 7: unterminated `s' command
[[email protected] ~]# echo "ABCabc" | sed "s/[ABC] [abc]/xx/" <--- with space, with quotes
ABCabc
So either A or D depending if there's a typo or not.
The correct answer is A, becuase its trying to change 2 characters, and the only part in the string where there is a single uppercase and lowercase ABC or abc next to each others ir right in the middle, where AB->Ca<-bc which gets changed to xx, so ABxxbc
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
cast7omadrid1
Highly Voted 3 years agosugisho
Highly Voted 2 years, 4 months agoDjBouz
Most Recent 2 days, 17 hours agototalchod
1 week, 6 days agoAdam_H
2 months agoAdam_H
2 months agoAdam_H
2 months agoIamrandom
3 months, 1 week agoTT924
3 months, 2 weeks agomeer01
4 months, 2 weeks agoWellison
6 months, 3 weeks agoWellison
6 months, 3 weeks agoLazylinux
10 months, 3 weeks agogonzaloco
11 months agoKiddyLitty
11 months, 1 week agoMartiFC
1 year, 1 month agok3n_
1 year, 1 month agominhng99
1 year, 2 months agoanhcq
1 year, 3 months agoKicoRox
1 year, 5 months ago