inxi is a full featured CLI system information tool. It is available in most Linux distribution repositories, and does its best to support the BSDs.
Go to file
inxi-svn 0c5674b4f9 (change version)
New option: -t 
requires extra args c, m, or cm (cpu, memory, or both). Accepts further additional option: 1-20

This will show top cpu processes for default number or user selection, and top memory using processes.

Sample: inxi -t c7
2010-02-13 01:21:29 +00:00
inxi (change version) 2010-02-13 01:21:29 +00:00