Friday, February 15, 2013

Newline after every character

I was printing some results for a chart while, after 10 minutes of executing the test, I realised I forgot to put the \n command after the number I wanted to print. I know the numbers I was printing were smaller than 10, so I came up with a useful command to append a new line after each character in a file:

sed 's/\(.\)/\1\n/g' -i filename

And that's it. As easy as that. I'm sorry for the lack of updates but lately I've been very busy.
Categories: ,

1 comment:

  1. You have invested a princely sum in the clothes you wear replica watches of your life, you have also hire done of the classiest cars but what about the watch. You will never be able to exhaust the entire of these replica watches sale even if you keep a different one in all the rooms of your condominium. Most professional who wear these fake rolex sale has confessed that they have found a new image of themselves after they have started wearing these rolex replica watches. So what are you waiting for. Get one of the countless models of the Replica Rolex Sea Dweller Watches and see your life change immediately. Not only will the girls at the party shower all their replica watches on you, you can be rest assured that even your boss will pay special attention at you. Rolex Replica Watches perform these wonders and lots more. It is amazing to note the number of people who shop for rolex replica sale. They are educated people and yet they search the net for a replica watch.

    ReplyDelete