Random draw

Dear support team,

I would like interviewers to randomly assign current respondent into one group (say group A or group B). My goal is to do such a randomization using tablet instead of asking the respondent to mechanically make a drawn from a box. I would also want to have a field which stores information about selected group. How can I do that? Thank you.