hello friends! new(ish)!

ASCII Rune: Difference between revisions

From InstallGentoo Wiki v2
Jump to navigation Jump to search
>Millysoose
(programming concept)
 
>Linux
No edit summary
 
(4 intermediate revisions by 4 users not shown)
Line 1: Line 1:
ASCII runes are an important component of the hoon programming language. They replace the awkard practice of using keywords.
ASCII runes are an important component of the hoon [[Programming languages|programming language]]. They replace the awkward practice of using keywords.


=== Table of Glyphs ===
=== Table of Glyphs ===
Line 29: Line 29:
       $(b +(b))
       $(b +(b))


When translated, this become's "luslus dec sigfas cen dec bartis a tis pat sigbar soq dec soq ketcab pat wutgal tis pel zero a per tislus b tis pat barhep wutcol tis pel a lus pel b per per b buc pel b lus pel b per per", which is far simpler.
When translated, this becomes "luslus dec sigfas cen dec bartis a tis pat sigbar soq dec soq ketcab pat wutgal tis pel zero a per tislus b tis pat barhep wutcol tis pel a lus pel b per per b buc pel b lus pel b per per", which is far simpler.




=== More information ===
=== More information ===
This wiki entry is largely taken from the [https://github.com/cgyarvin/urbit/blob/master/doc/book/3-syntax.markdown official documentation].
This wiki entry is largely taken from the [https://github.com/cgyarvin/urbit/blob/master/doc/book/3-syntax.markdown official documentation].
[[Category:Programming]]
[[Category:Programming languages]]

Latest revision as of 01:21, 22 June 2020

ASCII runes are an important component of the hoon programming language. They replace the awkward practice of using keywords.

Table of Glyphs

ace  space      gal  <          per  )
bar  |          gar  >          sel  [
bas  \          hax  #          sem  ;
buc  $          hep  -          ser  ]
cab  _          kel  {          sig  ~
cen  %          ker  }          soq  '
col  :          ket  ^          tar  *
com  ,          lus  +          tec  `
doq  "          pam  &          tis  =
dot  .          pat  @          wut  ?
fas  /          pel  (          zap  !

Two glyphs make a digraph. For instance +: is a digraph pronounced as lus-col.

This is the decrement function written in hoon.

++  dec
      ~/  %dec
      |=  a=@
      ^-  @
      ?<  =(0 a)
      =+  b=@
      |-
      ?:  =(a +(b))
        b
      $(b +(b))

When translated, this becomes "luslus dec sigfas cen dec bartis a tis pat sigbar soq dec soq ketcab pat wutgal tis pel zero a per tislus b tis pat barhep wutcol tis pel a lus pel b per per b buc pel b lus pel b per per", which is far simpler.


More information

This wiki entry is largely taken from the official documentation.