79804517

Date: 2025-10-30 08:18:27
Score: 1.5
Natty:
Report link

Brifly

cat 1.txt | sed -E "s/(.{1})/\1\n/g" | sort | uniq

Example:

cd /dev/shm/

echo "Hello_world" > /dev/shm/1.txt

cat 1.txt

cat 1.txt | sed -E "s/(.{1})/\1\n/g" | sort | uniq -с

S means substitute

S/str2replace/replacment/g g-means globaly

() is groupe

dot means any character

{1} exactly 1 character

All together

s/(.{1})/\1\n/g means replace any character exactly one with itself and char(10) that represents newline.

Reasons:
  • No code block (0.5):
  • Low reputation (1):
Posted by: Victor Adamenja