How to count computers and users in Active Directory?

This is really quick tip (cmd commands):

dsquery user -limit 10000 | find /c /i "OU="

To count users.

dsquery computer -limit 10000 | find /c /i "OU="

Here you can find how to create paths.