# I want to build "Which Harry Potter character are you?" app

Hello.
I want to build “Which Harry Potter character are you?” app, but don’t know how to link a different question for each choices, and get different ending.
( If Q1 ans a → Q2 → ans a → Q4 → ans a → Yes! you are Harry Potter.
____________________________–> ans b → you are Ron Weasley.
_______________ → ans b → Q5 …
_____ans b → Q3 → ans a → Q6 …
_______________–> ans b → Q2 …
like this)
Please help! I put some block together but cannot find a way to do so …T T
Thank you.

The fastest method i can think of is this:
I assume that you have many questions to ask in order, lets say A, B, C, D, E, F …
I also assume that every question has multiple answers, lets say 4 for each, like 1,2,3,4 (you can set question to a label, and answers to labeled buttons that once pressed will display you the next question and so on).
All you have to do is to define a variable (lets call it xANSERS) that will grow as answers are given:

After all questions have been anwered, you simple use some if else if block
So, if xANSWERS =“1111…” then user is like …
else if xANSWERS="1211… and so on…
1 Like

Great idea! Thank you so much. Very helpful.   Actually, what I tried to figure it out, is how to get to the next question in specific order depends on the answers.
For example:

• Question : A B C D E F G … Z

• Answer : 1 2 3 4

• Ending answer : Harry Ron Hermione Dobby …

Second problem is how to get to the ending answer by your method.

• if I do 10 question’s round, that make 4^10 ways of xANSWERS.   so confused right now 