You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
알고리즘이 매우 비효율적.
이중 while문을 돌리는데 바깥에선 마피아의수, 안에서는 iterator.hasnext()
랜덤수를 생성해서 값이 1이면 iterator.next()는 마피아가 됨.
1이 아니면 시민으로 설정.
실행해보면 되긴 되는데 몇번째가 마피아가 되느냐에 따라 버그가 생기기도 하는 것 같다.(아닐수도 있고..)