Planning to build a PC in couple of weeks.

What is the optimal number of cores to have without having diminishing returns?