#digit extraction problem