擅长:python、mysql、java
<p>在web生成器和Python中,只有<code>test</code>(后面没有空行)的文本,我得到的MD5哈希为:</p>
<pre><code>098f6bcd4621d373cade4e832627b4f6
</code></pre>
<p>如果在之后添加回车符/新行(\n),则会得到:</p>
^{pr2}$
<p>这种差异是由回车/换行类型造成的。DOS/Windows <code>('\r\n')</code>——Linux <code>('\n')</code></p>
<p><a href="http://www.cs.toronto.edu/~krueger/csc209h/tut/line-endings.html" rel="nofollow">http://www.cs.toronto.edu/~krueger/csc209h/tut/line-endings.html</a></p>