Description: Famous paintings gallery arranged by the nm × a rectangular array of showroom component. In order to prevent the paintings stolen, you need to set the security robot sentinel showroom. Each robot in addition to monitoring its security in the showroom, but also can monitor it in the showroom and the adjacent, down, left and right four showrooms. Try to design a robot sentinel security arrangements for the algorithm, makes the paintings galleries in every showroom are under surveillance by security robots, and robots used in the least number of guards.
Algorithm Design:
Design a priority queue-type branch and bound method to calculate the best robot sentinel security arrangements, making paintings in each gallery showroom are under surveillance by security robots, and robots used in the least number of guards.
Data entry:
The first line has two positive integers m and n (1 ≤ m, n ≤ 20).
The resulting output:
The first line is the number of security robots the next m rows in
To Search:
File list (Check if you may need any files):
chenlieguan\chenlieguan.cpp
...........\chenlieguan.dsp
...........\chenlieguan.dsw
...........\chenlieguan.ncb
...........\chenlieguan.opt
...........\chenlieguan.plg
...........\Debug\chenlieguan.exe
...........\.....\chenlieguan.ilk
...........\.....\chenlieguan.obj
...........\.....\chenlieguan.pch
...........\.....\chenlieguan.pdb
...........\.....\vc60.idb
...........\.....\vc60.pdb
...........\Debug
chenlieguan