detect tablet from user agent

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