Lua basics: Loops

Home Forums General Programming Lua basics: Loops

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #73567
    human fly
    Participant
      • Topics: 124
      • Replies: 1070
      • Total: 1194
      • ★★★★

      for us Lua newbie babies (and because i just made this
      and others might find it useful), here’s a little panel
      demonstrating ‘for’, ‘while’, and ‘repeat…until’, as per
      the tutorials here:

      https://www.tutorialspoint.com/lua/lua_loops.htm

      found that ‘for’ includes the bounds values whereas
      the other two start from the next value – unless
      someone can show how to avoid that with a=a+1

      Attachments:
      You must be logged in to view attached files.
      #73597
      dnaldoog
      Participant
        • Topics: 4
        • Replies: 480
        • Total: 484
        • ★★

        Great! – didn’t know about repeat .. until (condition==true) loops.

        #73603
        human fly
        Participant
          • Topics: 124
          • Replies: 1070
          • Total: 1194
          • ★★★★

          hey, have a look here, you might enjoy this little panel:

          simple sequencer

          a small issue at the moment as it loads, but recompile
          the method, and it runs.

        Viewing 3 posts - 1 through 3 (of 3 total)
        • The forum ‘Programming’ is closed to new topics and replies.
        There is currently 0 users and 74 guests online
        No users are currently active
        Forum Statistics
        Threads: 2,495, Posts: 17,374, Members: 77,605
        Most users ever online was 12 on January 22, 2019 3:47 pm
        Ctrlr