detect tablet from user agent

Android mobiles has value "Mobile" in their user agent.
It can be used to identiy tablet devices.
http://googlewebmastercentral.blogspot.in/2011/03/mo-better-to-also-detect-mobile-user.html