CS计算机代考程序代写 from csp import CSP

from csp import CSP
canterbury_colouring = CSP(
var_domains={
‘christchurch’: {‘red’, ‘green’},
‘selwyn’: {‘red’, ‘green’},
‘waimakariri’: {‘red’, ‘green’},
},
constraints={
lambda christchurch, waimakariri: christchurch != waimakariri,
lambda christchurch, selwyn: christchurch != selwyn,
lambda selwyn, waimakariri: selwyn != waimakariri,
})

#Unchanged since for every option in every domain there is an option in the
#corresponding domain that does not equal it