mixed difficulty

When does a firm maximize its profit in the factor market?