文件名称:TheBoredomDivTwo
介绍说明--下载内容均来自于网络,请自行研究使用
topcoder 698 题目 John and Brus are bored. They have n+m common friends. The first n of them are bored and other m are not. John chooses the j-th (1-based) friend for a talk. If the friend is not bored, he becomes bored after the talk. Brus does the same with the b-th (1-based) friend. Note that John and Brus can t choose the same friend.
You have to find the number of bored friends after the talks. -John and Brus are bored. They have n+m common friends. The first n of them are bored and other m are not. John chooses the j-th (1-based) friend for a talk. If the friend is not bored, he becomes bored after the talk. Brus does the same with the b-th (1-based) friend. Note that John and Brus can t choose the same friend.
You have to find the number of bored friends after the talks.
You have to find the number of bored friends after the talks. -John and Brus are bored. They have n+m common friends. The first n of them are bored and other m are not. John chooses the j-th (1-based) friend for a talk. If the friend is not bored, he becomes bored after the talk. Brus does the same with the b-th (1-based) friend. Note that John and Brus can t choose the same friend.
You have to find the number of bored friends after the talks.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
TheBoredomDivTwo.cpp