Posted By

lamebollock on 06/11/11


Tagged

Bash head cat charachters


Versions (?)

Linux command (like cat) to read a specified quantity of characters


 / Published in: Bash
 

URL: http://stackoverflow.com/questions/218912/linux-command-like-cat-to-read-a-specified-quantity-of-characters

Is there a command like cat in linux which can return a specified quantity of characters from a file?

  1. head -c 100 file # returns the first 100 bytes in the file
  2. tail -c 100 file # returns the last 100 bytes in the file
  3. dd count=5 bs=1 if=filename

Report this snippet  

You need to login to post a comment.