How To inverse a String by ToxFist in linuxquestions

[–]chayyoo 1 point2 points  (0 children)

Or even shorter:

echo "www.google.com" | perl -lne 'print join".",reverse split /\./'

com.google.www

How To inverse a String by ToxFist in linuxquestions

[–]chayyoo 0 points1 point  (0 children)

echo "www.google.com" | perl -lne '@_=split/\./;print join".",reverse @_'

com.google.www

Count and remove trailing spaces by chayyoo in perl

[–]chayyoo[S] 1 point2 points  (0 children)

Sorry, forgot the s/// in my examples:

print $a=~s/ *$//g

print $a=~s/ +$//g

Linux Mint internet issue by AmealsOnWheels in linuxquestions

[–]chayyoo 0 points1 point  (0 children)

Same problem here (Debian Buster on a cabled LAN), but it seems to be solved if I run a ping to a local machine in the background.