I need a script for bash that can accomplish this task
1. A list of the people currently logged in and for how long they are up.
2. A list of processes currently running, showing the userid, process id, CPU and memory usage, and command name. Sort these by either userid or process id (your choice, you don't have to support both), but make sure whichever you sort by is the first column.
3. Another list of processes, showing only the top 10 based on memory usage, sorted by memory usage. Include the same fields as above, but showing memory usage in the first column.
Any help will be greatly appreciated Thanks in advance!