foobar.foo
Source file: foobar/foo.py
foo module.
bar() ¶
<div class="doc-signature highlight"><pre><span></span><code><span id="__span-0-1"><a id="__codelineno-0-1" name="__codelineno-0-1" href="#__codelineno-0-1"></a><span class="n">bar</span><span class="p">(</span><span class="n">data</span><span class="p">:</span> <span class="o"><</span><span class="n">span</span> <span class="n">data</span><span class="o">-</span><span class="n">autorefs</span><span class="o">-</span><span class="n">optional</span><span class="o">=</span><span class="s2">"list"</span><span class="o">></span><span class="nb">list</span><span class="o"></</span><span class="n">span</span><span class="o">></span><span class="p">[</span><span class="o"><</span><span class="n">span</span> <span class="n">data</span><span class="o">-</span><span class="n">autorefs</span><span class="o">-</span><span class="n">optional</span><span class="o">=</span><span class="s2">"int"</span><span class="o">></span><span class="nb">int</span><span class="o"></</span><span class="n">span</span><span class="o">></span><span class="p">]</span> <span class="o">|</span> <span class="kc">None</span> <span class="o">=</span> <span class="kc">None</span><span class="p">)</span> <span class="o">-></span> <span class="o"><</span><span class="n">span</span> <span class="n">data</span><span class="o">-</span><span class="n">autorefs</span><span class="o">-</span><span class="n">optional</span><span class="o">=</span><span class="s2">"int"</span><span class="o">></span><span class="nb">int</span><span class="o"></</span><span class="n">span</span><span class="o">></span> <span class="o">|</span> <span class="kc">None</span><span class="p">(</span>
</span><span id="__span-0-2"><a id="__codelineno-0-2" name="__codelineno-0-2" href="#__codelineno-0-2"></a> <span class="n">data</span><span class="p">:</span> <span class="n"><span data-autorefs-optional="list">list</span></span><span class="p">[</span><span class="n"><span data-autorefs-optional="int">int</span></span><span class="p">]</span> <span class="o">|</span> <span class="kc">None</span> <span class="o">=</span> <span class="kc">None</span><span class="p">,</span>
</span><span id="__span-0-3"><a id="__codelineno-0-3" name="__codelineno-0-3" href="#__codelineno-0-3"></a><span class="p">)</span> <span class="o">-></span> <span class="n"><span data-autorefs-optional="int">int</span></span> <span class="o">|</span> <span class="kc">None</span>
</span></code></pre></div>
Sum list of integers.
Parameters:
Returns:
-
int | None
–None
ifdata=None
else the integer sum ofdata
.