'One size doesn't fit all': Learning how many Examples to use for In-Context Learning for Improved Text Classification