## Problem Description and Formulation

The problem is an optimization problem that involves minimizing an objective function subject to several constraints. The objective function to be minimized is:

\[ 4 \times \text{hours worked by Mary} + 7 \times \text{hours worked by Paul} + 3 \times \text{hours worked by John} \]

The constraints are:

1. **Individual Ratings and Scores**:
   - Mary's computer competence rating: 14
   - Mary's organization score: 9
   - Paul's computer competence rating: 3
   - Paul's organization score: 9
   - John's computer competence rating: 8
   - John's organization score: 9

2. **Combined Computer Competence Ratings**:
   - \( 14 \times \text{hours worked by Mary} + 8 \times \text{hours worked by John} \geq 22 \)
   - \( 14 \times \text{hours worked by Mary} + 3 \times \text{hours worked by Paul} \geq 16 \)
   - \( 14 \times \text{hours worked by Mary} + 3 \times \text{hours worked by Paul} + 8 \times \text{hours worked by John} \geq 16 \)

3. **Combined Organization Scores**:
   - \( 9 \times \text{hours worked by Mary} + 9 \times \text{hours worked by Paul} \geq 14 \)
   - \( 9 \times \text{hours worked by Mary} + 9 \times \text{hours worked by John} \geq 8 \)
   - \( 9 \times \text{hours worked by Paul} + 9 \times \text{hours worked by John} \geq 21 \)
   - \( 9 \times \text{hours worked by Mary} + 9 \times \text{hours worked by Paul} + 9 \times \text{hours worked by John} \geq 21 \)

4. **Additional Constraints**:
   - \( 5 \times \text{hours worked by Mary} - 8 \times \text{hours worked by John} \geq 0 \)
   - \( \text{hours worked by Mary} \) must be an integer
   - \( \text{hours worked by Paul} \) must be an integer
   - \( \text{hours worked by John} \) must be an integer

## Gurobi Code Formulation

```python
import gurobi

def solve_optimization_problem():
    # Create a new model
    model = gurobi.Model()

    # Define the variables
    mary_hours = model.addVar(name="mary_hours", vtype=gurobi.GRB.INTEGER)
    paul_hours = model.addVar(name="paul_hours", vtype=gurobi.GRB.INTEGER)
    john_hours = model.addVar(name="john_hours", vtype=gurobi.GRB.INTEGER)

    # Objective function
    model.setObjective(4 * mary_hours + 7 * paul_hours + 3 * john_hours, gurobi.GRB.MINIMIZE)

    # Constraints
    model.addConstr(14 * mary_hours + 8 * john_hours >= 22, name="combined_computer_rating_mary_john")
    model.addConstr(14 * mary_hours + 3 * paul_hours >= 16, name="combined_computer_rating_mary_paul")
    model.addConstr(14 * mary_hours + 3 * paul_hours + 8 * john_hours >= 16, name="combined_computer_rating_all")

    model.addConstr(9 * mary_hours + 9 * paul_hours >= 14, name="combined_organization_score_mary_paul")
    model.addConstr(9 * mary_hours + 9 * john_hours >= 8, name="combined_organization_score_mary_john")
    model.addConstr(9 * paul_hours + 9 * john_hours >= 21, name="combined_organization_score_paul_john")
    model.addConstr(9 * mary_hours + 9 * paul_hours + 9 * john_hours >= 21, name="combined_organization_score_all")

    model.addConstr(5 * mary_hours - 8 * john_hours >= 0, name="additional_constraint")

    # Solve the model
    model.optimize()

    # Print the solution
    if model.status == gurobi.GRB.OPTIMAL:
        print("Optimal Solution:")
        print(f"Mary's hours: {mary_hours.varValue}")
        print(f"Paul's hours: {paul_hours.varValue}")
        print(f"John's hours: {john_hours.varValue}")
        print(f"Objective: {model.objVal}")
    else:
        print("No optimal solution found.")

solve_optimization_problem()
```