LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Guys! I need help with some comands! Probobly simple for you :) (https://www.linuxquestions.org/questions/linux-newbie-8/guys-i-need-help-with-some-comands-probobly-simple-for-you-4175555265/)

fng77 10-04-2015 12:56 PM

Guys! I need help with some comands! Probobly simple for you :)
 
I need to list some files:

With ordinary commands and combine them with pipes, so that you get following result:

List all files, bigger than 1MB in a catalog (dont know witch to choose, something with not to many files). Dont list subfolders, and sort everything in a list.


Help please!

shivee 10-04-2015 01:05 PM

hi!
http://unix.stackexchange.com/questi...ze-recursively
http://www.howtogeek.com/168135/list...size-on-linux/

I think the above links would be helpful.Edit your title stating your actual problem so that you could receive proper response!

fng77 10-04-2015 01:18 PM

Quote:

Originally Posted by shivee (Post 5429746)
hi!
http://unix.stackexchange.com/questi...ze-recursively
http://www.howtogeek.com/168135/list...size-on-linux/

I think the above links would be helpful.Edit your title stating your actual problem so that you could receive proper response!

I got it done!

With: find . -maxdepth 1 -type f -size +100M


Thanks!





Now i must count the uniqe lines in a file named address.txt containing:

kalle
kalle
adam
olla
kalle


The command should output 3 of course. Any command you can recommend?

:)

jkirchner 10-05-2015 05:14 AM

Is this homework? You should not be asking for answers to homework questions especially if you don't even tell us what you have tried yet. You may wantr to review the rules about homework again.

Quote:

Do not post homework assignments verbatim. We're happy to assist if you have specific questions or have hit a stumbling point, however. Let us know what you've already tried and what references you have used (including class notes, books, and searches) and we'll do our best to help. Keep in mind that your instructor might also be an LQ member.
Here is a link to more info for you: http://www.linuxcommand.org/

fng77 10-05-2015 05:22 AM

Sorry!

I solved it myself :) got totaly stuck. Was only looking to learn, not for you to do it for me.

HMW 10-05-2015 07:06 AM

Quote:

Originally Posted by jkirchner (Post 5430038)
Is this homework?

Not only is this homework. I am 95% certain I know which course and University it is!

Mind you, I don't mind answering homework questions, as long as people at least have the decency to be upfront about it.

<rant>I know, I know, starting to sound like a bitter old fart, but... this ”give me, give me, give me” attitude is driving me nuts.
And, for the record, without the GNU/Linux community I would have gotten nowhere. But for all that is holy, unless you TRY, and try really HARD, you're never going to learn anything.</rant>


HMW

ericson007 10-05-2015 08:37 AM

Dear op, could you be so kind as to share what you did. I don't know about others but majority of my technical posts, I tryto leave behind what I did to solve the issue. Many others do the same. This is important since we do not appreciate answering the same questions over and over. It also benefits others searching. In turn they will find an answer and in turn members can answer other technical issues.

fng77 10-05-2015 09:37 AM

Quote:

Originally Posted by HMW (Post 5430080)
Not only is this homework. I am 95% certain I know which course and University it is!

Mind you, I don't mind answering homework questions, as long as people at least have the decency to be upfront about it.

<rant>I know, I know, starting to sound like a bitter old fart, but... this ”give me, give me, give me” attitude is driving me nuts.
And, for the record, without the GNU/Linux community I would have gotten nowhere. But for all that is holy, unless you TRY, and try really HARD, you're never going to learn anything.</rant>


HMW


I dont understand why it matters if its homework, work or private? Its a problem I got to solve and I asked for help in a forum. Thanks any way.

fng77 10-05-2015 09:46 AM

Quote:

Originally Posted by ericson007 (Post 5430115)
Dear op, could you be so kind as to share what you did. I don't know about others but majority of my technical posts, I tryto leave behind what I did to solve the issue. Many others do the same. This is important since we do not appreciate answering the same questions over and over. It also benefits others searching. In turn they will find an answer and in turn members can answer other technical issues.

Hi!

Now im not sure if I dare to answer. Im pretty new in this game and did know it was "forbidden" to ask certian questions. I give you a hint. I used the command sort and uniq.

Good luck!

If I have done anything wrong or broken some rule or something, I ask a mod to close this thread. Thanks!

NGIB 10-05-2015 09:47 AM

Quote:

Originally Posted by fng77 (Post 5430149)
I dont understand why it matters if its homework, work or private? Its a problem I got to solve and I asked for help in a forum. Thanks any way.

What have you learned if someone does the work for you? Seriously, look at the word: HOMEWORK it's work YOU are supposed to do.

What is a degree or certification worth if it's not earned? Nothing...

fng77 10-05-2015 10:05 AM

Quote:

Originally Posted by NGIB (Post 5430154)
What have you learned if someone does the work for you? Seriously, look at the word: HOMEWORK it's work YOU are supposed to do.

What is a degree or certification worth if it's not earned? Nothing...


I dont want anybody to do it FOR me. Im so new to linux, so I didnt know where to start :) Sometimes you need to ask somebody to get started.

I always ask people about advice when I cant figure it out myself. I see your point too, but that wasnt my goal at all. I always do everything myself, probably more than others do. But sometimes I get stuck and need help.

Sorry if I have offended someone here. Is it ok to ask qustions about work? or are you risking to be labeled as incompetent or something then? Not fit for the job?

I rest my case, this was not a good idea. I have learned something new :)

Thank god I didnt ask the teacher! He probobly would have expeld me for asking such stupid questions.

HMW 10-05-2015 10:22 AM

Quote:

Originally Posted by fng77 (Post 5430158)
But sometimes I get stuck and need help.

We ALL do.

I don't know if you misunderstood me (and others) here on purpose. Like I wrote earlier, I have absolutely nothing against helping out with homework, provided that the OP (you in this case) shows that [sh]e has tried to solve the issue first.

There was no attempt from you in your first posts. You did however show that you managed to solve the problems on your own. Awesome!

In the future, perhaps if you provided something like:
Quote:

I have homework and have to solve issue X.
My attempts this far looks like Y.
But... I get result A instead of B.
My thinking is that the problem lies in section C.
You wouldn't get such a, ehm, lukewarm reception. I don't know you, there is absolutely zero animosity from me towards you as a person. I wish you the best of luck in your future endeavours in GNU/Linux, and I sincerely believe that if you take my advice above, things will be smoother for you. But that is, of course, entirely up to you.

http://catb.org/~esr/faqs/smart-questions.html

Best regards,
HMW

fng77 10-05-2015 10:47 AM

He, he, sorry guys!

I see what you mean :)

The thing is, that I have been so bloody ill for about 3 months. I never have been like this before. Yesterday I got panic, when realizing that nothing had been done! My brain have lost its ability to think logical!!

Its comming back slowly...

Thanks for your reply! I agree totaly. Could have asked in a differnt way :)

See you around!

HMW 10-05-2015 10:50 AM

Quote:

Originally Posted by fng77 (Post 5430190)

Thanks for your reply! I agree totaly. Could have asked in a differnt way :)

See you around!

Thanks for YOUR reply. Looking forward to seeing more of you around.

Best regards,
HMW


All times are GMT -5. The time now is 05:34 PM.