How to compare the stored values of 2 different users?

Hey so I have a project in app inventor which is due next week, and the app I'm making is similar to tinder where the user chooses a movie and that choice is stored in a tinywebdb and is compared to the other user's choice (currently two users only). But I'm stuck on the part where I have to retrieve both values and compare them. How do I do it?
Here is my code (I know it's wrong but I'm stuck) :


and here is what the app looks like :

Ok so you did not provide your blocks where you store and retrieve data from tinyWebDb.

I can give you a small logic which can be used.

Store an empty dictionary in a tag
Your keys in the dictionary should be the movie names.
Your value for each movie must be a list containing the users who have chosen the specific movie.

After this you can do the needful.........

can you send me the blocks in which you do it? I'm still new to app inventor

This is a sample block. You will have to change it to your needs

ok so i call this block whenever a user chooses a movie?

Nono,

See you have to develop your own logic.

  • Like when a user choses a movie, and if it isnt added to your dictionary you will have to add it.
  • When a new user selects a movie, you will have to use the add item to list block to store the username in the respective movie's value.

okay and how do i compare them ?

So i dont know why you would like to 'compare' them and what do you mean by it.
As far as I understood, you would like to see if two users have chosen the same movie.
Am i right?

For that you can try this block.

Hope this helps :smile:

alright I'll try it. The reason i wanna compare them is if they have chosen the same movie a message box will tell them that they chose the same one

So after I choose a movie you can use a label to display the names of other people who have chosen the movie.
Like this -

okay thanks I'll try them out and tell you what happens