Skip to main content
deleted 18 characters in body
Source Link
Unrelated String
  • 23.9k
  • 3
  • 37
  • 61

Jelly, 31 2828 27 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZJm2BỊḄJ=&ɗⱮJḤṚ|Ɗị"Ø^;;⁶Ʋ€UZ

Try it online!Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely. It seems tantalizingly simple with certain praclang tools, but with so much to juggle, it comes out suprisingly clunky in Jelly!

Returns a list of lines.

Jm2BỊḄ&þJ=J€$ḤṚ|ƊJm2BỊḄJ=&ɗⱮJḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ    ɗⱮJ        tabledFor witheach [1 .. length].,
        =& =          is Isits eachbitwise elementAND ofwith each rowmask equal to
      J    J€$         the length1-index of thethat rowmask?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZ    Format the tree:
ị              Modular 1-index each row into
 "     Ʋ€      the corresponding character
  Ø^;          appended to "/\"
     ;⁶        with a space appended.
         U     Reverse each row
          Z    and transpose.

Jelly, 31 28 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZ

Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely. It seems tantalizingly simple with certain praclang tools, but with so much to juggle, it comes out suprisingly clunky in Jelly!

Returns a list of lines.

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ            tabled with [1 .. length].
         =           Is each element of each row equal to
          J€$        the length of the row?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZ    Format the tree:
ị              Modular 1-index each row into
 "     Ʋ€      the corresponding character
  Ø^;          appended to "/\"
     ;⁶        with a space appended.
         U     Reverse each row
          Z    and transpose.

Jelly, 31 28 27 bytes

Jm2BỊḄJ=&ɗⱮJḤṚ|Ɗị"Ø^;;⁶Ʋ€UZ

Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely. It seems tantalizingly simple with certain praclang tools, but with so much to juggle, it comes out suprisingly clunky in Jelly!

Returns a list of lines.

Jm2BỊḄJ=&ɗⱮJḤṚ|Ɗ    Build the tree:
Jm2                 For every [1, 3 .. length],
   B                take its arbitrary-length binary representation
     Ḅ              and convert back from binary
    Ị               with all bits set to 1.
Jm2BỊḄ              This creates a bitmask for the period of that column.
         ɗⱮJ        For each [1 .. length],
       =&           is its bitwise AND with each mask equal to
      J             the 1-index of that mask?
            ḤṚ      Double and reverse the comparisons
              |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZ    Format the tree:
ị              Modular 1-index each row into
 "     Ʋ€      the corresponding character
  Ø^;          appended to "/\"
     ;⁶        with a space appended.
         U     Reverse each row
          Z    and transpose.
added 282 characters in body
Source Link
Unrelated String
  • 23.9k
  • 3
  • 37
  • 61

Jelly, 31 2928 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZYJm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZ

Try it online!Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely. It seems tantalizingly simple with certain praclang tools, but with so much to juggle, it comes out suprisingly clunky in Jelly!

Returns a list of lines.

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ            tabled with [1 .. length].
         =           Is each element of each row equal to
          J€$        the length of the row?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZYị"Ø^;;⁶Ʋ€UZ    Format the tree:
ị               Modular 1-index each row into
 "     Ʋ€       the corresponding character
  Ø^;           appended to "/\"
     ;⁶         with a space appended.
         U      Reverse each row,
          Z     transpose,
           Y    and join on newlinestranspose.

Jelly, 31 29 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZY

Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely.

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ            tabled with [1 .. length].
         =           Is each element of each row equal to
          J€$        the length of the row?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZY    Format the tree:
ị               Modular 1-index each row into
 "     Ʋ€       the corresponding character
  Ø^;           appended to "/\"
     ;⁶         with a space appended.
         U      Reverse each row,
          Z     transpose,
           Y    and join on newlines.

Jelly, 31 28 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZ

Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely. It seems tantalizingly simple with certain praclang tools, but with so much to juggle, it comes out suprisingly clunky in Jelly!

Returns a list of lines.

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ            tabled with [1 .. length].
         =           Is each element of each row equal to
          J€$        the length of the row?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZ    Format the tree:
ị              Modular 1-index each row into
 "     Ʋ€      the corresponding character
  Ø^;          appended to "/\"
     ;⁶        with a space appended.
         U     Reverse each row
          Z    and transpose.
added 111 characters in body
Source Link
Unrelated String
  • 23.9k
  • 3
  • 37
  • 61

Jelly, 31 29 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZY

Try it online!Try it online!

Yikes... Still feels prettya little golfable, but it might just be the wrong approach entirely.

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ            tabled with [1 .. length].
         =           Is each element of each row equal to
          J€$        the length of the row?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZY    Format the tree:
ị               Modular 1-index each row into
 "     Ʋ€       the corresponding character
  Ø^;           appended to "/\"
     ;⁶         with a space appended.
         U      Reverse each row,
          Z     transpose,
           Y    and join on newlines.

Jelly, 31 29 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZY

Try it online!

Yikes... Still feels pretty golfable, but it might just be the wrong approach entirely.

Jelly, 31 29 bytes

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZY

Try it online!

Yikes... Still feels a little golfable, but it might just be the wrong approach entirely.

Jm2BỊḄ&þJ=J€$ḤṚ|Ɗ    Build the tree:
Jm2                  For every [1, 3 .. length],
   B                 take its arbitrary-length binary representation
     Ḅ               and convert back from binary
    Ị                with all bits set to 1.
Jm2BỊḄ               This creates a bitmask for the period of that column.
      &              Bitwise AND
       þJ            tabled with [1 .. length].
         =           Is each element of each row equal to
          J€$        the length of the row?
             ḤṚ      Double and reverse the comparisons
               |Ɗ    and bitwise OR with the original comparisons.

ị"Ø^;;⁶Ʋ€UZY    Format the tree:
ị               Modular 1-index each row into
 "     Ʋ€       the corresponding character
  Ø^;           appended to "/\"
     ;⁶         with a space appended.
         U      Reverse each row,
          Z     transpose,
           Y    and join on newlines.
added 111 characters in body
Source Link
Unrelated String
  • 23.9k
  • 3
  • 37
  • 61
Loading
Source Link
Unrelated String
  • 23.9k
  • 3
  • 37
  • 61
Loading