checking number of processes