Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

linux commands help!!!

  • 07-07-2011 12:58am
    #1
    Closed Accounts Posts: 3


    hey guys am kinda gettin started on linux and how to use and stuff and would appreciate any help how to i write the following shell commands or pipelines to output the messages:

    1)one
    two
    three
    the solution must involve a loop

    2)list all running process belonging to the user with account name "jones".


    3)count the number of times the text blubber occurs in the file book.txt leaving the number in the file count.txt


Comments

  • Closed Accounts Posts: 20,759 ✭✭✭✭dlofnep


    1. Using a bash script..
    array=(one two three)

    for i in "${array[@]}"
    do
    echo $i
    done


  • Registered Users, Registered Users 2 Posts: 6,265 ✭✭✭MiCr0


    university - is this homework or does it have some purpose?

    I've unapproved 2 of the replies as it looks like they're doing your work for you


  • Registered Users, Registered Users 2 Posts: 297 ✭✭stesh


    how about
    man
    


  • Registered Users, Registered Users 2 Posts: 1,931 ✭✭✭PrzemoF


    OP, no one will do it for you

    ad 1. sorry I don't understand what do you want to achieve
    ad 2. man ps
    ad 3. man grep, man wc, google for "linux pipe"


Advertisement