擅长:python、mysql、java
<p>使用单独的子句检查<code>"quit"</code>和<code>"now"</code>是否都在<code>ChatCommand</code>中,例如</p>
<pre><code>if "quit" in ChatCommand and "now" in ChatCommand:
</code></pre>
<p>注意,在Python中,<a href="https://publib.boulder.ibm.com/infocenter/lnxpcomp/v8v101/index.jsp?topic=%2Fcom.ibm.xlcpp8l.doc%2Flanguage%2Fref%2Flogande.htm" rel="nofollow">logical and operator</a>&;是<code>and</code>,<code>&</code>是<a href="http://en.wikipedia.org/wiki/Bitwise_operation#AND" rel="nofollow">bitwise and</a>。你知道吗</p>