how to read number of processor core in linux code example Example: linux check cpu core lscpu #or cat /proc/cpuinfo