Example Arrow Word

ASnake Documentation

Table Of Contents

    Turns a word into an arrow pointing right.

    Code:

    arrow does
        loop amount x 
            if x < amount//2 then f"{' '*x then word}"
            else f"{' '*abs(x-amount) then word}"
        word 
    from str word,int amount = 12
    
    'hi' to arrow
    

    Result:

    hi
     hi
      hi
       hi
        hi
         hi
          hi
         hi
        hi
       hi
      hi
     hi
    hi
    
    Scroll to top