#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2003
    Posts
    17
    Rep Power
    0

    how do i display one line from a file?


    say if i want to display the first line of /etc/passwd instead of the whole file.
    how do i do that?
  2. #2
  3. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2003
    Posts
    17
    Rep Power
    0
    for example if i want read the first 3 fields from line 1, output to a file; then first 3 fields from line 2, add output to the end of that file...and so on. how can i do that?
    thanks

IMN logo majestic logo threadwatch logo seochat tools logo