<snapdata remixID="8921525"><project name="4.4" app="Snap! 5.1, http://snap.berkeley.edu" version="1"><notes></notes><thumbnail>data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKAAAAB4CAYAAAB1ovlvAAADL0lEQVR4Xu3WsU1jURAF0GcIKIAW6IE+TCF0QB2IhEKQaILIKTEiIeevINhkN/zSHbjHBbyZuffI9mHbtm35SCCUwAHAUPLGficAIAjRBACMxm84gAxEEwAwGr/hADIQTQDAaPyGA8hANAEAo/EbDiAD0QQAjMZvOIAMRBMAMBq/4QAyEE0AwGj8hgPIQDQBAKPxGw4gA9EEAIzGbziADEQTADAav+EAMhBNAMBo/IYDyEA0AQCj8RsOIAPRBACMxm84gAxEEwAwGr/hADIQTQDAaPyGA8hANAEAo/EbDiAD0QQAjMZvOIAMRBMAMBq/4QAyEE0AwGj8hgPIQDQBAKPxGw4gA9EEAIzGbziADEQTADAav+EAMhBNAMBo/IYDyEA0AQCj8RsOIAPRBACMxm84gAxEEwAwGr/hADIQTQDAaPyGA8hANAEAd4h/27bvVw6Hww6vdT0B4E5939zcrM/Pz3U6ndbj4+O6vr7e6eXf/QyAO/X79S14PB7/ee39/X09Pz+v8/PznSb9rmcA3LHP29vb9fr6+t8XPz4+1v39/bq6utpx4s9/CsCdOnx5eVl3d3d/Xzs7O1uXl5fr4eFhpwm/8xkAd+j16+f36z/g29vbenp6WhcXFzu82vEEgB09j70SwLHVdCwGYEfPY68EcGw1HYsB2NHz2CsBHFtNx2IAdvQ89koAx1bTsRiAHT2PvRLAsdV0LAZgR89jrwRwbDUdiwHY0fPYKwEcW03HYgB29Dz2SgDHVtOxGIAdPY+9EsCx1XQsBmBHz2OvBHBsNR2LAdjR89grARxbTcdiAHb0PPZKAMdW07EYgB09j70SwLHVdCwGYEfPY68EcGw1HYsB2NHz2CsBHFtNx2IAdvQ89koAx1bTsRiAHT2PvRLAsdV0LAZgR89jrwRwbDUdiwHY0fPYKwEcW03HYgB29Dz2SgDHVtOxGIAdPY+9EsCx1XQsBmBHz2OvBHBsNR2LAdjR89grARxbTcdiAHb0PPZKAMdW07EYgB09j70SwLHVdCwGYEfPY68EcGw1HYsB2NHz2CsBHFtNx2IAdvQ89koAx1bTsRiAHT2PvfIP2eMLtyTkcb0AAAAASUVORK5CYII=</thumbnail><stage name="Stage" width="480" height="360" costume="0" color="255,255,255,1" tempo="60" threadsafe="false" volume="100" pan="0" lines="round" ternary="false" codify="false" inheritance="true" sublistIDs="false" scheduled="false" id="1"><pentrails>data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAeAAAAFoCAYAAACPNyggAAAOhUlEQVR4Xu3VwQkAAAjEMN1/abewn7jAQRC64wgQIECAAIF3gX1fNEiAAAECBAiMAHsCAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQICLAfIECAAAECgYAAB+gmCRAgQICAAPsBAgQIECAQCAhwgG6SAAECBAgIsB8gQIAAAQKBgAAH6CYJECBAgIAA+wECBAgQIBAICHCAbpIAAQIECAiwHyBAgAABAoGAAAfoJgkQIECAgAD7AQIECBAgEAgIcIBukgABAgQIHLFxAWmhEwHPAAAAAElFTkSuQmCC</pentrails><costumes><list struct="atomic" id="2"></list></costumes><sounds><list struct="atomic" id="3"></list></sounds><variables></variables><blocks></blocks><scripts></scripts><sprites><sprite name="Sprite" idx="1" x="34" y="-1" heading="90" scale="1" volume="100" pan="0" rotation="1" draggable="true" costume="0" color="80,80,80,1" pen="tip" id="8"><costumes><list struct="atomic" id="9"></list></costumes><sounds><list struct="atomic" id="10"></list></sounds><blocks></blocks><variables></variables><scripts><script x="515" y="226"><custom-block s="average"></custom-block></script><script x="472" y="227"><custom-block s="sum"></custom-block></script><script x="590" y="223"><custom-block s="includes negative"></custom-block></script><script x="716" y="222"><custom-block s="increasing"></custom-block></script><script x="799" y="219"><custom-block s="maximum"></custom-block></script><script x="325" y="217"><custom-block s="make all positive"></custom-block></script><script x="316" y="283"><custom-block s="only evens"></custom-block></script></scripts></sprite><watcher var="list" style="normal" x="10" y="10" color="243,118,29" hidden="true"/><watcher var="sum" style="normal" x="10" y="103.000002" color="243,118,29" hidden="true"/></sprites></stage><hidden></hidden><headers></headers><code></code><blocks><block-definition s="append %&apos;lists&apos;" type="reporter" category="lists"><comment x="0" y="0" w="287" collapsed="false">Take any number of input lists, and create a new list&#xD;containing the items of the input lists.  So&#xD;APPEND [A B] [C D]&#xD;where the [...] are lists reports the list&#xD;[A B C D]&#xD;not [[A B] [C D]].</comment><header></header><code></code><translations>ca:concatena _&#xD;</translations><inputs><input type="%mult%l"></input></inputs><script><block s="doWarp"><script><block s="doIf"><block s="reportEquals"><block var="lists"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doIf"><block s="reportEquals"><block s="reportListLength"><block var="lists"/></block><l>1</l></block><script><block s="doReport"><block s="reportListItem"><l>1</l><block var="lists"/></block></block></script></block><block s="doIf"><block s="reportEquals"><block s="reportListItem"><l>1</l><block var="lists"/></block><block s="reportNewList"><list></list></block></block><script><block s="doReport"><custom-block s="append %mult%l"><block s="reportCDR"><block var="lists"/></block></custom-block></block></script></block><block s="doReport"><block s="reportCONS"><block s="reportListItem"><l>1</l><block s="reportListItem"><l>1</l><block var="lists"/></block></block><custom-block s="append %mult%l"><block s="reportCONS"><block s="reportCDR"><block s="reportListItem"><l>1</l><block var="lists"/></block></block><block s="reportCDR"><block var="lists"/></block></block></custom-block></block></block></script></block></script></block-definition><block-definition s="reverse %&apos;data&apos;" type="reporter" category="lists"><comment x="0" y="0" w="223" collapsed="false">Reports a new list containing the items of the input list, but in the opposite order.</comment><header></header><code></code><translations>ca:capgira _&#xD;</translations><inputs><input type="%l"></input></inputs><script><block s="doDeclareVariables"><list><l>helper</l></list></block><block s="doSetVar"><l>helper</l><block s="reifyScript"><script><block s="doIf"><block s="reportEquals"><block var="input"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block var="result"/></block></script></block><block s="doReport"><block s="evaluate"><block var="helper"/><list><block s="reportCDR"><block var="input"/></block><block s="reportCONS"><block s="reportListItem"><l>1</l><block var="input"/></block><block var="result"/></block></list></block></block></script><list><l>input</l><l>result</l></list></block></block><block s="doWarp"><script><block s="doReport"><block s="evaluate"><block var="helper"/><list><block var="data"/><block s="reportNewList"><list></list></block></list></block></block></script></block></script></block-definition><block-definition s="remove duplicates from %&apos;data&apos;" type="reporter" category="lists"><comment x="0" y="0" w="209" collapsed="false">Reports a new list whose items are the same as in the input list, except that if two or more equal items appear in the input list, only the last one is kept in the result.</comment><header></header><code></code><translations>ca:elimina els duplicats de _&#xD;</translations><inputs><input type="%l"></input></inputs><script><block s="doWarp"><script><block s="doIf"><block s="reportEquals"><block var="data"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doIfElse"><block s="reportListContainsItem"><block s="reportCDR"><block var="data"/></block><block s="reportListItem"><l>1</l><block var="data"/></block></block><script><block s="doReport"><custom-block s="remove duplicates from %l"><block s="reportCDR"><block var="data"/></block></custom-block></block></script><script><block s="doReport"><block s="reportCONS"><block s="reportListItem"><l>1</l><block var="data"/></block><custom-block s="remove duplicates from %l"><block s="reportCDR"><block var="data"/></block></custom-block></block></block></script></block></script></block></script></block-definition><block-definition s="sort %&apos;data&apos; ordering with %&apos;function&apos;" type="reporter" category="lists"><comment x="0" y="0" w="161.14285714285708" collapsed="false">Reports a sorted version of the list in its first input slot, using the comparison function in the second input slot.  For a list of numbers, using &lt; as the comparison function will sort from low to high; using &gt; will sort from high to low.</comment><header></header><code></code><translations>ca:ordena _ segons criteri _&#xD;</translations><inputs><input type="%l"></input><input type="%predRing"></input></inputs><script><block s="doDeclareVariables"><list><l>even items</l><l>odd items</l><l>merge</l><l>split</l><l>copy of data</l><l>id</l></list></block><block s="doSetVar"><l>id</l><block s="reifyScript"><script><block s="doReport"><l></l></block></script><list></list></block></block><block s="doSetVar"><l>copy of data</l><block s="reportMap"><block var="id"/><block var="data"/></block></block><block s="doSetVar"><l>split</l><block s="reifyScript"><script><block s="doSetVar"><l>even items</l><block s="reportNewList"><list></list></block></block><block s="doSetVar"><l>odd items</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportListIsEmpty"><block var="copy of data"/></block><script><block s="doAddToList"><block s="reportListItem"><l>1</l><block var="copy of data"/></block><block var="odd items"/></block><block s="doDeleteFromList"><l>1</l><block var="copy of data"/></block><block s="doIf"><block s="reportNot"><block s="reportListIsEmpty"><block var="copy of data"/></block></block><script><block s="doAddToList"><block s="reportListItem"><l>1</l><block var="copy of data"/></block><block var="even items"/></block><block s="doDeleteFromList"><l>1</l><block var="copy of data"/></block></script></block></script></block></script><list></list></block></block><block s="doSetVar"><l>merge</l><block s="reifyScript"><script><block s="doIf"><block s="reportEquals"><block var="#1"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block var="#2"/></block></script></block><block s="doIf"><block s="reportEquals"><block var="#2"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block var="#1"/></block></script></block><block s="doIfElse"><block s="evaluate"><block var="function"/><list><block s="reportListItem"><l>1</l><block var="#1"/></block><block s="reportListItem"><l>1</l><block var="#2"/></block></list></block><script><block s="doReport"><block s="reportCONS"><block s="reportListItem"><l>1</l><block var="#1"/></block><block s="evaluate"><block var="merge"/><list><block s="reportCDR"><block var="#1"/></block><block var="#2"/></list></block></block></block></script><script><block s="doReport"><block s="reportCONS"><block s="reportListItem"><l>1</l><block var="#2"/></block><block s="evaluate"><block var="merge"/><list><block var="#1"/><block s="reportCDR"><block var="#2"/></block></list></block></block></block></script></block></script><list><l>#1</l><l>#2</l></list></block></block><block s="doIf"><block s="reportEquals"><block var="data"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doIf"><block s="reportEquals"><block s="reportCDR"><block var="data"/></block><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block var="data"/></block></script></block><block s="doRun"><block var="split"/><list></list></block><block s="doReport"><block s="evaluate"><block var="merge"/><list><custom-block s="sort %l ordering with %predRing"><block var="odd items"/><block var="function"/></custom-block><custom-block s="sort %l ordering with %predRing"><block var="even items"/><block var="function"/></custom-block></list></block></block></script></block-definition><block-definition s="assoc %&apos;key&apos; %&apos;a-list&apos;" type="reporter" category="lists"><comment x="0" y="0" w="289.3333333333333" collapsed="false">The second input is an &quot;association list,&quot; a list of two-item lists.  Each of those smaller lists has a &quot;key&quot; as its first item and a &quot;value&quot; as its second.  ASSOC reports the first key-value pair in the association list whose key matches the first input.</comment><header></header><code></code><translations>ca:associació _ _&#xD;</translations><inputs><input type="%s"></input><input type="%l"></input></inputs><script><block s="doIf"><block s="reportEquals"><block var="a-list"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doIf"><block s="reportEquals"><block var="key"/><block s="reportListItem"><l>1</l><block s="reportListItem"><l>1</l><block var="a-list"/></block></block></block><script><block s="doReport"><block s="reportListItem"><l>1</l><block var="a-list"/></block></block></script></block><block s="doReport"><custom-block s="assoc %s %l"><block var="key"/><block s="reportCDR"><block var="a-list"/></block></custom-block></block></script></block-definition><block-definition s="%&apos;#&apos; map %&apos;function&apos; over %&apos;lists&apos;" type="reporter" category="lists"><comment x="0" y="0" w="225.00000000000003" collapsed="false">This block applies the given function to each item of the given list, like the primitive MAP block, but with two differences:&#xD;&#xD;1.  The # variable provided will contain the item number of the item currently being used in the given function: 1 for item 1, and so on.  You read the variable in your function; don&apos;t set it.&#xD;&#xD;2.  You can provide more than one input list.  If so, the lengths of all the lists should be the same, and the function you supply must expect as many inputs as you have lists (i.e., that many empty input slots in the function).</comment><header></header><code></code><translations>ca:_ mapeja _ sobre _&#xD;</translations><inputs><input type="%upvar"></input><input type="%repRing"></input><input type="%mult%l"></input></inputs><script><block s="doWarp"><script><block s="doDeclareVariables"><list><l>mapone</l><l>mapmany</l></list></block><block s="doSetVar"><l>mapone</l><block s="reifyScript"><script><block s="doIf"><block s="reportListIsEmpty"><block var="data"/></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doSetVar"><l>#</l><block var="count"/></block><block s="doReport"><block s="reportCONS"><block s="evaluate"><block var="function"/><list><block s="reportListItem"><l>1</l><block var="data"/></block></list></block><block s="evaluate"><block var="mapone"/><list><block s="reportCDR"><block var="data"/></block><block s="reportSum"><block var="count"/><l>1</l></block></list></block></block></block></script><list><l>data</l><l>count</l></list></block></block><block s="doSetVar"><l>mapmany</l><block s="reifyScript"><script><block s="doIf"><block s="reportListIsEmpty"><block s="reportListItem"><l>1</l><block var="data lists"/></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doSetVar"><l>#</l><block var="count"/></block><block s="doReport"><block s="reportCONS"><block s="evaluate"><block var="function"/><custom-block s="%upvar map %repRing over %mult%l"><l>#</l><block s="reifyReporter"><autolambda><block s="reportListItem"><l>1</l><l/></block></autolambda><list></list></block><list><block var="data lists"/></list></custom-block></block><block s="evaluate"><block var="mapmany"/><list><custom-block s="%upvar map %repRing over %mult%l"><l>#</l><block s="reifyReporter"><autolambda><block s="reportCDR"><l/></block></autolambda><list></list></block><list><block var="data lists"/></list></custom-block><block s="reportSum"><block var="count"/><l>1</l></block></list></block></block></block></script><list><l>data lists</l><l>count</l></list></block></block><block s="doIfElse"><block s="reportListIsEmpty"><block s="reportCDR"><block var="lists"/></block></block><script><block s="doReport"><block s="evaluate"><block var="mapone"/><list><block s="reportListItem"><l>1</l><block var="lists"/></block><l>1</l></list></block></block></script><script><block s="doReport"><block s="evaluate"><block var="mapmany"/><list><block var="lists"/><l>1</l></list></block></block></script></block></script></block></script></block-definition><block-definition s="%&apos;#&apos; keep items %&apos;pred&apos; from %&apos;data&apos;" type="reporter" category="lists"><comment x="0" y="0" w="217.1428571428572" collapsed="false">This block makes a new list containing selected items from the given list, like the primitive KEEP block.&#xD;&#xD;What&apos;s different is that it provides the # variable for use in your predicate function.  It will contain the item number (in the original list) of the item being examined by the predicate.</comment><header></header><code></code><translations>ca:_ manté els elements on _ de _&#xD;</translations><inputs><input type="%upvar"></input><input type="%predRing"></input><input type="%l"></input></inputs><script><block s="doDeclareVariables"><list><l>keep-helper</l></list></block><block s="doSetVar"><l>keep-helper</l><block s="reifyScript"><script><block s="doWarp"><script><block s="doIf"><block s="reportListIsEmpty"><block var="data"/></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doSetVar"><l>#</l><block var="count"/></block><block s="doIfElse"><block s="evaluate"><block var="pred"/><list><block s="reportListItem"><l>1</l><block var="data"/></block></list></block><script><block s="doReport"><block s="reportCONS"><block s="reportListItem"><l>1</l><block var="data"/></block><block s="evaluate"><block var="keep-helper"/><list><block s="reportCDR"><block var="data"/></block><block s="reportSum"><block var="count"/><l>1</l></block></list></block></block></block></script><script><block s="doReport"><block s="evaluate"><block var="keep-helper"/><list><block s="reportCDR"><block var="data"/></block><block s="reportSum"><block var="count"/><l>1</l></block></list></block></block></script></block></script></block></script><list><l>data</l><l>count</l></list></block></block><block s="doReport"><block s="evaluate"><block var="keep-helper"/><list><block var="data"/><l>1</l></list></block></block></script></block-definition><block-definition s="%&apos;#&apos; for each %&apos;item&apos; of %&apos;data&apos; %&apos;action&apos;" type="command" category="lists"><comment x="0" y="0" w="228.57142857142858" collapsed="false">This block carries out the given script for each item of the given list, like the primitive FOR EACH.&#xD;&#xD;What&apos;s different is that it provides the # variable, which will contain the item number in the list of each item in turn, 1 while processing item 1, and so on.</comment><header></header><code></code><translations>ca:_ per cada _ de _ _&#xD;</translations><inputs><input type="%upvar"></input><input type="%upvar"></input><input type="%l"></input><input type="%ca"></input></inputs><script><block s="doSetVar"><l>#</l><l>1</l></block><block s="doUntil"><block s="reportListIsEmpty"><block var="data"/></block><script><block s="doSetVar"><l>item</l><block s="reportListItem"><l>1</l><block var="data"/></block></block><block s="doRun"><block var="action"/><list><block s="reportListItem"><l>1</l><block var="data"/></block></list></block><block s="doSetVar"><l>data</l><block s="reportCDR"><block var="data"/></block></block><block s="doChangeVar"><l>#</l><l>1</l></block></script></block></script></block-definition><block-definition s="%&apos;head&apos; in front of stream %&apos;tail&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:a prefixação de _ ao canal _&#xD;</translations><inputs><input type="%s"></input><input type="%anyUE"></input></inputs><script><block s="doReport"><block s="reportNewList"><list><block var="head"/><block var="tail"/><block s="reportBoolean"><l><bool>false</bool></l></block><block s="reportBoolean"><l><bool>false</bool></l></block></list></block></block></script></block-definition><block-definition s="head of stream %&apos;stream&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:o primeiro item do canal _&#xD;</translations><inputs><input type="%l"></input></inputs><script><block s="doReport"><block s="reportListItem"><l>1</l><block var="stream"/></block></block></script></block-definition><block-definition s="tail of stream %&apos;stream&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:um canal com todos os itens de _ menos o primeiro&#xD;</translations><inputs><input type="%l"></input></inputs><script><block s="doWarp"><script><block s="doIf"><block s="reportListItem"><l>3</l><block var="stream"/></block><script><block s="doReport"><block s="reportListItem"><l>4</l><block var="stream"/></block></block></script></block><block s="doReplaceInList"><l>4</l><block var="stream"/><block s="evaluate"><block s="reportListItem"><l>2</l><block var="stream"/></block><list></list></block></block><block s="doReplaceInList"><l>3</l><block var="stream"/><block s="reportBoolean"><l><bool>true</bool></l></block></block><block s="doReport"><block s="reportListItem"><l>4</l><block var="stream"/></block></block></script></block></script></block-definition><block-definition s="map %&apos;function&apos; over stream %&apos;stream&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:a aplicação de _ aos itens dos canais _&#xD;</translations><inputs><input type="%repRing"></input><input type="%mult%l"></input></inputs><script><block s="doWarp"><script><block s="doIf"><block s="reportEquals"><block s="reportListItem"><l>1</l><block var="stream"/></block><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doReport"><custom-block s="%s in front of stream %anyUE"><block s="evaluate"><block var="function"/><custom-block s="map %repRing over %mult%l"><block s="reifyReporter"><autolambda><custom-block s="head of stream %l"><l/></custom-block></autolambda><list></list></block><list><block var="stream"/></list></custom-block></block><custom-block s="map %repRing over stream %mult%l"><block var="function"/><custom-block s="map %repRing over %mult%l"><block s="reifyReporter"><autolambda><custom-block s="tail of stream %l"><l/></custom-block></autolambda><list></list></block><list><block var="stream"/></list></custom-block></custom-block></custom-block></block></script></block></script></block-definition><block-definition s="keep items such that %&apos;pred&apos; from stream %&apos;stream&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:os itens tais que _ do canal _&#xD;</translations><inputs><input type="%predRing"></input><input type="%l"></input></inputs><script><block s="doWarp"><script><block s="doIf"><block s="reportEquals"><block var="stream"/><block s="reportNewList"><list></list></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doIfElse"><block s="evaluate"><block var="pred"/><list><custom-block s="head of stream %l"><block var="stream"/></custom-block></list></block><script><block s="doReport"><custom-block s="%s in front of stream %anyUE"><custom-block s="head of stream %l"><block var="stream"/></custom-block><custom-block s="keep items such that %predRing from stream %l"><block var="pred"/><custom-block s="tail of stream %l"><block var="stream"/></custom-block></custom-block></custom-block></block></script><script><block s="doReport"><custom-block s="keep items such that %predRing from stream %l"><block var="pred"/><custom-block s="tail of stream %l"><block var="stream"/></custom-block></custom-block></block></script></block></script></block></script></block-definition><block-definition s="map %&apos;function&apos; over %&apos;lists&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:a aplicação de _ aos itens de _&#xD;</translations><inputs><input type="%repRing"></input><input type="%mult%l"></input></inputs><script><block s="doWarp"><script><block s="doDeclareVariables"><list><l>mapone</l><l>mapmany</l></list></block><block s="doSetVar"><l>mapone</l><block s="reifyScript"><script><block s="doIf"><block s="reportListIsEmpty"><block var="data"/></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doReport"><block s="reportCONS"><block s="evaluate"><block var="function"/><list><block s="reportListItem"><l>1</l><block var="data"/></block></list></block><block s="evaluate"><block var="mapone"/><list><block s="reportCDR"><block var="data"/></block></list></block></block></block></script><list><l>data</l></list></block></block><block s="doSetVar"><l>mapmany</l><block s="reifyScript"><script><block s="doIf"><block s="reportListIsEmpty"><block s="reportListItem"><l>1</l><block var="data lists"/></block></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doReport"><block s="reportCONS"><block s="evaluate"><block var="function"/><custom-block s="map %repRing over %mult%l"><block s="reifyReporter"><autolambda><block s="reportListItem"><l>1</l><l/></block></autolambda><list></list></block><list><block var="data lists"/></list></custom-block></block><block s="evaluate"><block var="mapmany"/><list><custom-block s="map %repRing over %mult%l"><block s="reifyReporter"><autolambda><block s="reportCDR"><l/></block></autolambda><list></list></block><list><block var="data lists"/></list></custom-block></list></block></block></block></script><list><l>data lists</l></list></block></block><block s="doIfElse"><block s="reportListIsEmpty"><block s="reportCDR"><block var="lists"/></block></block><script><block s="doReport"><block s="evaluate"><block var="mapone"/><list><block s="reportListItem"><l>1</l><block var="lists"/></block></list></block></block></script><script><block s="doReport"><block s="evaluate"><block var="mapmany"/><list><block var="lists"/></list></block></block></script></block></script></block></script></block-definition><block-definition s="empty? %&apos;data&apos;" type="predicate" category="lists"><header></header><code></code><translations>pt:o canal _ está vazio&#xD;</translations><inputs><input type="%l"></input></inputs><script><block s="doReport"><block s="reportEquals"><block var="data"/><block s="reportNewList"><list></list></block></block></block></script></block-definition><block-definition s="show stream %&apos;stream&apos; %&apos;number&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:uma lista com os itens do canal _ até ao _ º&#xD;</translations><inputs><input type="%l"></input><input type="%n">10</input></inputs><script><block s="doIf"><custom-block s="empty? %l"><block var="stream"/></custom-block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doIf"><block s="reportEquals"><block var="number"/><l>0</l></block><script><block s="doReport"><block s="reportNewList"><list></list></block></block></script></block><block s="doReport"><block s="reportCONS"><custom-block s="head of stream %l"><block var="stream"/></custom-block><custom-block s="show stream %l %n"><custom-block s="tail of stream %l"><block var="stream"/></custom-block><block s="reportDifference"><block var="number"/><l>1</l></block></custom-block></block></block></script></block-definition><block-definition s="stream %&apos;items&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:um canal com _&#xD;</translations><inputs><input type="%mult%s"></input></inputs><script><block s="doIf"><custom-block s="empty? %l"><block var="items"/></custom-block><script><block s="doReport"><block var="items"/></block></script></block><block s="doReport"><custom-block s="%s in front of stream %anyUE"><block s="reportListItem"><l>1</l><block var="items"/></block><custom-block s="stream %mult%s"><block s="reportCDR"><block var="items"/></block></custom-block></custom-block></block></script></block-definition><block-definition s="sieve %&apos;stream&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:a crivagem do canal _&#xD;</translations><inputs><input type="%l"></input></inputs><script><block s="doWarp"><script><block s="doReport"><custom-block s="%s in front of stream %anyUE"><custom-block s="head of stream %l"><block var="stream"/></custom-block><custom-block s="sieve %l"><custom-block s="keep items such that %predRing from stream %l"><block s="reifyPredicate"><autolambda><block s="reportGreaterThan"><block s="reportModulus"><l></l><custom-block s="head of stream %l"><block var="stream"/></custom-block></block><l>0</l></block></autolambda><list></list></block><custom-block s="tail of stream %l"><block var="stream"/></custom-block></custom-block></custom-block></custom-block></block></script></block></script></block-definition><block-definition s="stream with numbers from %&apos;o inicio&apos;" type="reporter" category="lists"><header></header><code></code><translations>pt:um canal com os números a partir de _&#xD;</translations><inputs><input type="%n">1</input></inputs><script><block s="doReport"><block s="reportNewList"><list><block var="o inicio"/><block s="reifyReporter"><autolambda><custom-block s="stream with numbers from %n"><block s="reportSum"><block var="o inicio"/><l>1</l></block></custom-block></autolambda><list></list></block><block s="reportBoolean"><l><bool>false</bool></l></block><block s="reportBoolean"><l><bool>false</bool></l></block></list></block></block></script></block-definition><block-definition s="sum" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doSayFor"><block s="reportSum"><block s="reportListItem"><l>1</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>2</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>3</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>4</l><block var="list"/></block><block s="reportListItem"><l>5</l><block var="list"/></block></block></block></block></block><l>2</l></block><block s="doReport"><l></l></block></script></block-definition><block-definition s="average" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doSetVar"><l>sum</l><block s="reportSum"><block s="reportListItem"><l>1</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>2</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>3</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>4</l><block var="list"/></block><block s="reportListItem"><l>5</l><block var="list"/></block></block></block></block></block></block><block s="doSayFor"><block s="reportQuotient"><block var="sum"/><block s="reportListLength"><block var="list"/></block></block><l>2</l></block><block s="doReport"><l></l></block></script></block-definition><block-definition s="includes negative" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doForEach"><l>item</l><block var="list"/><script><block s="doIf"><block s="reportGreaterThan"><l>0</l><block var="item"/></block><script><block s="doReport"><block s="reportBoolean"><l><bool>true</bool></l></block></block></script></block></script></block><block s="doReport"><block s="reportBoolean"><l><bool>false</bool></l></block></block></script></block-definition><block-definition s="increasing" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doIfElse"><block s="reportEquals"><block s="reportListItem"><l>2</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>1</l><block var="list"/></block><l>1</l></block></block><script><block s="doIfElse"><block s="reportEquals"><block s="reportListItem"><l>3</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>2</l><block var="list"/></block><l>1</l></block></block><script><block s="doIfElse"><block s="reportEquals"><block s="reportListItem"><l>4</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>3</l><block var="list"/></block><l>1</l></block></block><script><block s="doIfElse"><block s="reportEquals"><block s="reportListItem"><l>5</l><block var="list"/></block><block s="reportSum"><block s="reportListItem"><l>4</l><block var="list"/></block><l>1</l></block></block><script><block s="doReport"><block s="reportBoolean"><l><bool>true</bool></l></block></block></script><script><block s="doReport"><block s="reportBoolean"><l><bool>false</bool></l></block></block></script></block></script><script><block s="doReport"><block s="reportBoolean"><l><bool>false</bool></l></block></block></script></block></script><script><block s="doReport"><block s="reportBoolean"><l><bool>false</bool></l></block></block></script></block></script><script><block s="doReport"><block s="reportBoolean"><l><bool>false</bool></l></block></block></script></block></script></block-definition><block-definition s="maximum" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doDeclareVariables"><list><l>maximum</l></list></block><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doSetVar"><l>maximum</l><block s="reportListItem"><l>1</l><block var="list"/></block></block><block s="doForEach"><l>item</l><block var="list"/><script><block s="doIf"><block s="reportGreaterThan"><block var="item"/><block var="maximum"/></block><script><block s="doSetVar"><l>maximum</l><block var="item"/></block></script></block></script></block><block s="doSayFor"><block var="maximum"/><l>2</l></block><block s="doReport"><block var="maximum"/></block></script></block-definition><block-definition s="make all positive" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doDeclareVariables"><list><l>#</l></list></block><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doRepeat"><block s="reportListLength"><block var="list"/></block><script><block s="doForEach"><l>item</l><block var="list"/><script><block s="doSetVar"><l>#</l><l>1</l></block><block s="doIf"><block s="reportGreaterThan"><l>0</l><block var="item"/></block><script><block s="doReplaceInList"><block var="#"/><block var="list"/><block s="reportProduct"><block var="item"/><l>-1</l></block></block></script></block><block s="doChangeVar"><l>#</l><l>1</l></block></script></block></script></block><block s="doSayFor"><block var="list"/><l>2</l></block><block s="doReport"><block var="list"/></block></script></block-definition><block-definition s="only evens" type="reporter" category="variables"><header></header><code></code><translations></translations><inputs></inputs><script><block s="doSetVar"><l>list</l><block s="reportNewList"><list></list></block></block><block s="doUntil"><block s="reportEquals"><block s="reportListLength"><block var="list"/></block><l>5</l></block><script><block s="doAsk"><l>What would you like a number to be?</l></block><block s="doAddToList"><block s="getLastAnswer"></block><block var="list"/></block></script></block><block s="doDeclareVariables"><list><l>evens</l><l>#</l></list></block><block s="doSetVar"><l>evens</l><block var="list"/></block><block s="doSetVar"><l>#</l><l>1</l></block><block s="doForEach"><l>item</l><block var="evens"/><script><block s="doIf"><block s="reportEquals"><block s="reportModulus"><block var="item"/><l>2</l></block><l>1</l></block><script><block s="doDeleteFromList"><block var="#"/><block var="evens"/></block></script></block><block s="doChangeVar"><l>#</l><l>1</l></block></script></block><block s="doSayFor"><block var="evens"/><l>2</l></block><block s="doReport"><block var="evens"/></block></script></block-definition></blocks><variables><variable name="list"><list struct="atomic" id="1638">6,5,6</list></variable><variable name="sum"><l>26</l></variable></variables></project><media name="4.4" app="Snap! 5.1, http://snap.berkeley.edu" version="1"></media></snapdata>