split numbers


    Sep 22 2009 | 10:15 pm
    How do you solve this?
    let's say you have the number 567 and you wnat to slice i up to 5 6 7 so you can send i to a select object to test it.
    Many thanks
    /Fredrik

    • Sep 22 2009 | 10:40 pm
      regexp allows you to do that.
    • Sep 23 2009 | 9:58 am
      many thanks
      /Fredrik
    • Sep 23 2009 | 10:29 am
      You can also use [% 10], [% 100], and other modulo and division operators to separate out individual digits. In some circumstances this can be easier than regexp.
    • Sep 23 2009 | 10:35 pm
      Yet another way would be to use atoi and then subtract 48 from all elements in the list using vexpr.
    • Sep 24 2009 | 9:20 am
      Thanks all. You are very kind!
    • Aug 21 2013 | 3:37 pm
      Hi
      I am trying something similar, but producing bangs to messages after selecting a number. However, it is only selecting the first digit and not the remaining two numbers.
      Is it even possible to do this with a delay 500 between each bang?
    • Aug 21 2013 | 8:00 pm
      @Joe: [zl queue]
      -