안전한 흐름
join before scope end
1
지역 변수 생성main scope 안에 value가 살아 있습니다.
2
std::ref 전달스레드가 value 원본을 참조합니다.
3
join으로 종료 대기스레드 접근이 끝난 뒤 scope가 닫힙니다.