Japanese authorities have captured a bear following a multi-day search that saw nearly 100 schools close.