It is possible to do basic math operations using Set User Attribute action block. These include adding, subtracting, multiplying, and dividing. The value section should contain the operations themselves, while the attribute field contains attributes that will display the result. This is most useful when creating a quiz or when you need to know a number of times the action took place.

image.png

Quiz

Math operations can help you create quizzes where your users answer questions and score points. To do this, simply add Set User Attribute plugin after every question to set the number of points scored. You can add, subtract, multiple or divide points. Look at the example below. Click here to expand the image.

Flow entry counter

Let’s say you want to know how many times the same user entered your Flow. For this, you will need to create an attribute with any name and add +1 to it in the value field. Like this:

  1. Add Set User Attribute block.

  2. Set attribute to {{flowentry}}.

  3. Set value to {{flowentry}}+1.

  4. Connect Set User Attribute block to your Flow.

Now, every time a user gets to a certain point of your Flow, the block will be triggered and the value of {{flowentry}} will go up by one.

image.png
Did this answer your question?