Anonymous user
Two sum: Difference between revisions
no edit summary
No edit summary |
|||
Line 285:
[]
</pre>
=={{header|Befunge}}==
<lang befunge>>000pv
>&:0\`#v_00g:1+00p6p
v >$&50p110p020p
v>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>+50g-!#v_48*10g8p10g1+:00g1-`v >
v >10g20g..@ v_v
"""""""""""""""""""""""""""""""""""""""""""""""v ">"p4\"v"p02:+1p4\">":g02$< :
> 20g8p20g1+:00g1-`#v_0 ^1
""""""""""""""""""""""""""""""""""""""""""""""" " 0
>^ l p
i "
a ^
F "
" \
>:#,_@ 8
p
> ^</lang>
There are a couple of caveats due to limitations of the language. The target cannot be above 127, there can be no more than 47 elements in the list and the list must be delimited by a negative number before the target value as follows:
<pre>
0 2 11 19 90 -1 21
</pre>
{{out}}
<pre>1 3</pre>
=={{header|C}}==
|