擅长:python、mysql、java
<p>您可以执行以下操作:</p>
<p><strong>Python 2.x</strong></p>
<pre><code>import hashlib
print hashlib.md5("whatever your string is").hexdigest()
</code></pre>
<hr/>
<p><strong>Python 3.x</strong></p>
<pre><code>import hashlib
print(hashlib.md5("whatever your string is".encode('utf-8')).hexdigest())
</code></pre>
<hr/>
<p>不过,在这种情况下,最好使用这个有用的Python模块与Flickr API交互:</p>
<ul>
<li><a href="http://stuvel.eu/flickrapi">http://stuvel.eu/flickrapi</a></li>
</ul>
<p>。。。它将为您处理身份验证。</p>
<p><a href="https://docs.python.org/2/library/hashlib.html#module-hashlib">hashlib</a>的正式文件</p>