Dfn: Difference between revisions

Jump to navigation Jump to search
126 bytes removed ,  06:00, 4 August 2020
Line 13: Line 13:
       3 {⍵*÷⍺} 27      ⍝ ⍺th root
       3 {⍵*÷⍺} 27      ⍝ ⍺th root
3
3
       ⍝ Multiline dfn with optional left parameter
       ⍝ Multiline dfn with optional left parameter and conditional result
       root←{
       root←{
           ⍺←2          ⍝ square root by default
           ⍺←2          ⍝ square root by default
          ⍵*÷⍺          ⍝ result
           ⍺=0:0        ⍝ return zero if zeroth root
      }
      ⍝ Dfn with conditional result
      root←{
          ⍺←2          ⍝ square root by default
           ⍺=0:0        ⍝ zero if zeroth root
           ⍵*÷⍺          ⍝ result
           ⍵*÷⍺          ⍝ result
       }</source>
       }</source>
trusted
69

edits

Navigation menu