Three word location: Difference between revisions
Content deleted Content added
added RPL |
|||
Line 1,365: | Line 1,365: | ||
To 3-word: ba duji be |
To 3-word: ba duji be |
||
From 3-word: -89.99999, -179.99999</pre> |
From 3-word: -89.99999, -179.99999</pre> |
||
=={{header|RPL}}== |
|||
{{works with|RPL|HP-49C}} |
|||
« 43 STWS DEC |
|||
{ 90 180 } ADD 10000 * IP R→I |
|||
EVAL SWAP 4194304 * + R→B |
|||
1 2 '''START''' |
|||
#3FFFh AND LASTARG 1 + / |
|||
'''NEXT''' |
|||
3 →LIST REVLIST |
|||
100000 ADD |
|||
1 « →STR 4 OVER SIZE 1 - SUB "W" SWAP + » DOLIST |
|||
» '<span style="color:blue">LL→W</span>' STO <span style="color:grey">''@ ( { latitude longitude } → { "word1" .. "word3" )''</span> |
|||
« « 2 OVER SIZE SUB STR→ » MAP |
|||
DUP 1 GET |
|||
2 3 '''FOR''' j |
|||
16384 * OVER j GET + |
|||
'''NEXT''' |
|||
NIP R→B #400000h / LASTARG 1 - AND |
|||
2 →LIST B→R 10000 / { 90 180 } - |
|||
» '<span style="color:blue">W→LL</span>' STO <span style="color:grey">''@ ( → { "word1" .. "word3" → { latitude longitude } )''</span> |
|||
{ 28.3852 -81.5638 } <span style="color:blue">LL→W</span> |
|||
DUP <span style="color:blue">W→LL</span> |
|||
{{out}} |
|||
<pre> |
|||
2: { "W18497" "W11324" "W01322" } |
|||
1: { 28.3852 -81.5638 } |
|||
</pre> |
|||
=={{header|Symsyn}}== |
=={{header|Symsyn}}== |