The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | May 2017 |
| Last Sign in: | 398 Weeks Ago, 5 Days Ago |
| Questions Answered: | 66690 |
| Tutorials Posted: | 66688 |
MCS,PHD
Argosy University/ Phoniex University/
Nov-2005 - Oct-2011
Professor
Phoniex University
Oct-2001 - Nov-2016
INC Pradnya team wants to publicize their event so as to get maximum participants. Hence the official INC Pradnya'15 head decides to send messages to students in Pune. However he has very little balance left on his phone. He cannot invite everybody. He can send only K messages.
A student receiving the message forwards it to all his friends. A person participates in the event only if he or she receives at least one message. Our Pradnya'15 head knows who is friends with whom. Using this knowledge he wants to reach out to maximum number of students.
Output the maximum students he can reach out to, on a single line
Â
Â
Â
Â
Â
Â
Â
Â
Â
Â
Input: 1 3 2 2 1 2 2 3 Output: 3
Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll