<divclass="content sourceset-depenent-content"data-active=""data-togglable=":kmath-core:dokkaHtmlPartial/commonMain"><divclass="symbol monospace"><spanclass="token keyword"></span><spanclass="token keyword">fun </span><spanclass="token operator"><</span><spanclass="token keyword"></span><ahref="sum-with.html">T</a><spanclass="token operator">></span><ahref="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-iterable/index.html">Iterable</a><spanclass="token operator"><</span><spanclass="token keyword"></span><ahref="sum-with.html">T</a><spanclass="token operator">></span><spanclass="token punctuation">.</span><ahref="sum-with.html"><spanclass="token function">sumWith</span></a><spanclass="token punctuation">(</span>group<spanclass="token operator">: </span><ahref="-group/index.html">Group</a><spanclass="token operator"><</span><spanclass="token keyword"></span><ahref="sum-with.html">T</a><spanclass="token operator">></span><spanclass="token punctuation">)</span><spanclass="token operator">: </span><ahref="sum-with.html">T</a><spanclass="top-right-position"><spanclass="copy-icon"></span><divclass="copy-popup-wrapper popup-to-left"><spanclass="copy-popup-icon"></span><span>Content copied to clipboard</span></div></span></div><pclass="paragraph">Returns the sum of all elements in the iterable in provided space.</p><h4class="">Receiver</h4><pclass="paragraph">the collection to sum up.</p><h4class="">Return</h4><pclass="paragraph">the sum.</p><h2class="">Parameters</h2><divdata-togglable="Parameters"><divclass="table"data-togglable="Parameters"><divclass="table-row"data-filterable-current=":kmath-core:dokkaHtmlPartial/commonMain"data-filterable-set=":kmath-core:dokkaHtmlPartial/commonMain"><divclass="main-subrow keyValue WithExtraAttributes"><divclass=""><spanclass="inline-flex"><div><span><span>group</span></span></div></span></div><div><divclass="title"><divdata-togglable="Parameters"><pclass="paragraph">the algebra that provides addition.</p></div></div></div></div></div></div></div><br><divclass="symbol monospace"><spanclass="token keyword"></span><spanclass="token keyword">fun </span><spanclass="token operator"><</span><spanclass="token keyword"></span><ahref="sum-with.html">T</a><spanclass="token operator">></span><ahref="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.sequences/-sequence/index.html">Sequence</a><spanclass="token operator"><</span><spanclass="token keyword"></span><ahref="sum-with.html">T</a><spanclass="token operator">></span><spanclass="token punctuation">.</span><ahref="sum-with.html"><spanclass="token function">sumWith</span></a><spanclass="token punctuation">(</span>group<spanclass="token operator">: </span><ahref="-group/index.html">Group</a><spanclass="token operator"><</span><spanclass="token keyword"></span><ahref="sum-with.html">T</a><spanclass="token operator">></span><spanclass="token punctuation">)</span><spanclass="token operator">: </span><ahref="sum-with.html">T</a><spanclass="top-right-position"><spanclass="copy-icon"></span><divclass="copy-popup-wrapper popup-to-left"><spanclass="copy-popup-icon"></span><span>Content copied to clipboard</span></div></span></div><pclass="paragraph">Returns the sum of all elements in the sequence in provided space.</p><h4class="">Receiver</h4><pclass="paragraph">the collection to sum up.</p><h4class="">Return</h4><pclass="paragraph">the sum.</p><h2class="">Parameters</h2><divdata-togglable="Parameters"><divclass="table"data-togglable="Parameters"><divclass="table-row"data-filterable-current=":kmath-core:dokkaHtmlPartial/commonMain"data-filterable-set=":kmath-core:dokkaHtmlPartial/commonMain"><divclass="main-subrow keyValue WithExtraAttributes"><divclass=""><spanclass="inline-flex"><div><span><span>group</span></span></div></span></div><div><divclass="title"><divdata-togglable="Parameters"><pclass="paragraph">the algebra that provides addition.</p></div></div></div></div></div></div></div></div>