Selection of workers and firm heterogeneity