It would depend on what you meant by "user activity".
Many programs run automated things under a "user" account (often an Administrative "user"). For example if a "user" ran something in background with a nohup it would continue to run even after the "user" logged out. Cron and at jobs can be kicked off for "users".
If what you're really interested in is whether a "user" is logged on an "doing" something I'd suggest running "who" to get a list of user's logged in then running a "ps -fu<user>" for each "user" reported by who and see what they're running. Many user's leave themselves logged in so if all you see are shells (bash, ksh, csh etc...) and no other processes they *probably* aren't "active" but you can't guarantee it because you might have just happen to run your ps in between commands they've typed. If they're all using GUIs it might be even more complicated.
You can try setting shell timeouts globally (e.g. set TMOUT variable in /etc/profile) so that new logins automatically logout after a certain amount of inactivity. However, some users try to circumvent this by doing something like "vi test" so the shell thinks they're doing something. (The wouldn't show as inactive and timeout until after they'd closed the vi session.) Of course you could check when the process started and kill it based on age. (e.g. if they started a vi at 11 AM and it's still there at 11 PM either they're very dedicated, they're very lazy or trying to circumvent - I'd just kill it off at that point - if they weren't smart enough to save 12 hours worth of work in a vi document or to recover from the swap file afterwords I don't have a lot of sympathy for them.)
P.S. I'm not the BOFH but I do like the way he thinks.