"A forest contains T trees numbered from 1 to T and P people numbered from 1 to P. Standard input consists of a line containing T and P followed by several lines, containing a pair of integers i and j, indicating that person i has heard tree j fall. People may have different opinions as to which trees, according to Berkeley, have made a sound."
실제 입력에서 첫 줄에 P, T 순으로 입력이 주어집니다. a line containing P and T로 수정 부탁 드립니다.
hjroh0315 4년 전 7
"A forest contains T trees numbered from 1 to T and P people numbered from 1 to P. Standard input consists of a line containing T and P followed by several lines, containing a pair of integers i and j, indicating that person i has heard tree j fall. People may have different opinions as to which trees, according to Berkeley, have made a sound."
실제 입력에서 첫 줄에 P, T 순으로 입력이 주어집니다. a line containing P and T로 수정 부탁 드립니다.