Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How do I modify a funtion that takes a directory name as an argument and writes to standard output the maximum of the lengths of all filenames in that directory to descend all subdirectories of the named directory recursively and to find the maximum length of any filename in that hierarchy?
and change the rest of the program into a shell script See the man pages for find and wc to learn how and why it works.
Quote:
How do I modify a funtion
Well, what language are you using? Also, out of curiousity, why? To help you, it might be useful for us to know a bit on your programming background, just so we know roughly how much to explain and how much to assume you already know.
Most of my programming background is in Microsoft (I know, dirty word in this world). To be honest, I need help understanding what I am doing in Linux enough to pass the last class I have before graduating in December. Any help is GREATLY appreciated!!
Is your question answered? Otherwise, please answer my previous questions: which language, and why? Also, please provide the code snippet you want changed.
Is your question answered? Otherwise, please answer my previous questions: which language, and why? Also, please provide the code snippet you want changed.
No, my question hasn't been answered. As far as the language I am using I don't know. We are used Fedora Core8. And, I am trying to change the code snippet that was the original to create it (I don't know that either). Can you help? Or,is there a web site that I can go to that will explain the basics of scripting for this program?
No, my question hasn't been answered. As far as the language I am using I don't know. We are used Fedora Core8. And, I am trying to change the code snippet that was the original to create it (I don't know that either). Can you help? Or,is there a web site that I can go to that will explain the basics of scripting for this program?
You want to modify a function, but you haven't shown us any code. If it exists, we need to see it. If it doesn't, then we must assume that you wanted to say "create", and not "modify".
You want us to give you info about how to change I don't know what function, in I don't know what language. I wonder if you really think we can give out feedback with the amount of info you gave us.
Show us the function, the original code snippet, and be clear about what modifications need to be done, and maybe someone around will recognize the language and give you some pointers, or direct you to some tutorials. But we can't direct you to tutorials about something that we don't even know what is.
How do I modify a funtion that takes a directory name as an argument and writes to standard output the maximum of the lengths of all filenames in that directory to descend all subdirectories of the named directory recursively and to find the maximum length of any filename in that hierarchy?
Do you have a specific function that you need to modify?
If so
What is the function you are trying to modify?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.