Part 1. Definition
You are given a dialog between 2 or more individuals. You need to generate the number of the speaker (e.g. 1 for Speaker 1) who had the most lines in the dialog. If there is a tie, output the answer '0'.
Part 2. Example
Speaker 1: What do you think we should do for our 10th wedding anniversary?
Speaker 2: Hm, how about we take a vacation? Somewhere sandy and warm.
Speaker 1: Well, if we're going to go out of the country, you need to be sure to renew your passport. It expired over a year ago!
Speaker 2: How about we get something expensive instead of travelling. We could get a new car.
Speaker 1: Is this your way of telling me that you want me to buy you a car?
Answer: 1
Explanation: In this dialog, there are 5 lines of speech. Three of them belong to Speaker 1 and two of them belong to Speaker 2. Therefore, Speaker 1 has the most lines in the dialog.
Part 3. Exercise
Speaker 1: What's the matter with me? How do I keep ruining this? I'm sorry, I'm sorry!
Speaker 2: No! It's my fault. I keep trying to propose in these stupid ways and all I wanna do is tell you that I love you and I want to spend the rest of my life with you.
Speaker 2: I'm gonna do this now.
Speaker 1: Oh my God!
Speaker 2: Phoebe, I...
Speaker 1: Wait! Oh wait! Oh no!
Speaker 2: Ready?
Speaker 1: Uh-huh!
Speaker 2: Phoebe, I love you. There's no-one else in the world I would ask to marry me... three times. But I wanna take care of you, have babies with you, and grow old with you... Phoebe Buffay, will you marry me?
Speaker 1: Yes!
Speaker 2: I love you!
Speaker 1: I love you more!
Answer:
1