Popular recipes tagged "paper"http://code.activestate.com/recipes/tags/paper/2016-05-05T23:47:49-07:00ActiveState Code RecipesFind Paper Format of based on Pixel Width and Height of a (PDF) Page (Python) 2016-05-05T23:47:49-07:00Harald Liederhttp://code.activestate.com/recipes/users/4191581/http://code.activestate.com/recipes/580659-find-paper-format-of-based-on-pixel-width-and-heig/ <p style="color: grey"> Python recipe 580659 by <a href="/recipes/users/4191581/">Harald Lieder</a> (<a href="/recipes/tags/a4/">a4</a>, <a href="/recipes/tags/format/">format</a>, <a href="/recipes/tags/letter/">letter</a>, <a href="/recipes/tags/paper/">paper</a>). </p> <p>A simple function to determine what format page a page in document has. Parameters provided are width and height in float or integer format.</p> <p>Return is a string like "A4-P" or "Letter-L" when an exact fit is found. If not, information is provided as a string like "width x height (other), closest &lt;format&gt; width x height". The closest format in this case is determined by minimizing the sum of absolute differences of width and height with a table of official formats.</p> Rock,Paper,Scissors (Python) 2014-12-19T05:39:38-08:00Burak Tandoganhttp://code.activestate.com/recipes/users/4191373/http://code.activestate.com/recipes/578983-rockpaperscissors/ <p style="color: grey"> Python recipe 578983 by <a href="/recipes/users/4191373/">Burak Tandogan</a> (<a href="/recipes/tags/game/">game</a>, <a href="/recipes/tags/paper/">paper</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/rock/">rock</a>, <a href="/recipes/tags/scissors/">scissors</a>). Revision 2. </p> <p>A simple game :)</p>