>>1の問題解いたから誰か採点ヨロ

https://ideone.com/P0qF0V