Skip to content

Commit

Permalink
Update search_and_matching_labour.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
Tortar authored Nov 30, 2024
1 parent afa320d commit a670e7f
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/markets/search_and_matching_labour.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,9 @@ function search_and_matching_labour(firms::AbstractFirms, model)
shuffle!(H_E)

# fire workers if vacancies are negative
for e in eachindex(H_E)
for h in H_E

# find employer of worker
h = H_E[e]
i = O_h[h]

# if employer has negative vacancies, fire the worker
Expand All @@ -53,9 +52,7 @@ function search_and_matching_labour(firms::AbstractFirms, model)
# while there are no more vacancies or unemployed workers
while !isempty(H_U) && !isempty(I_V)
shuffle!(I_V)
for f in eachindex(I_V)
# select random vacancy
i = I_V[f]
for i in I_V
# select random unemployed worker
h = H_U[1]
# employ worker
Expand Down

0 comments on commit a670e7f

Please sign in to comment.