擅长:python、mysql、java
<p>您可以将其更改为:</p>
<pre><code>def WorkDetails(link, details):
</code></pre>
<p>然后将其调用为:</p>
<pre><code>details = [ AllcurrValFound_bse, AllyearlyHLFound_bse,
AlldaysHLFound_bse, AllvolumeFound_bse,
AllprevCloseFound_bse, AllchangePercentFound_bse,
AllmarketCapFound_bse ]
workDetails(link, details)
</code></pre>
<p>您可以通过以下方法从细节中获取不同的值:</p>
<pre><code>AllcurrValFound_bse = details[0]
AllyearlyHLFound_bse = details[1]
...
</code></pre>
<p>将<code>details</code>转换为字典(变量名作为键)会更健壮,因此在多行代码和防御编程之间进行选择</p>