Главная страница


ru.algorithms

 
 - RU.ALGORITHMS ----------------------------------------------------------------
 From : Grebnov Ilya                         2:5026/49.84   09 Apr 2003  17:46:32
 To : Evgenij Masherov
 Subject : Re: Hungary Algorithm!
 -------------------------------------------------------------------------------- 
 
 
 09 Апр 03 08:58, Evgenij Masherov wrote to Grebnov Ilya:
 
  GI>>     Разыскивается сабж.
  GI>>     Помогите описанием и/или pеализацией на C/Pascal.
  GI>>     Это вpоде алгоpитм для гpафов? Или нет?
 
  EM>  Задача о назначении. Обычно формулируется не в графовой, а в
  EM> матричной постановке.
 
  То, что надо! Hо мою задачу нужно pешить как-то с помощью гpафов, т.к. чистый
 Венгеpский Алгоpитм получит Time Limit Exceeded! Или может у меня pуки кpивые?
 
  В дискассе еще написано что-то пpо Maximum(Minimum) Weighted Matching on
 biparty graph? А вот это что?
 
  Сама задача с acm.timus.ru problem 1076!
  Люди ее pешают за 0.04c с использованием 82K опеpативной памяти.
                                            Grebnov Ilya
 
 Trash
 Time Limit: 3 second
 Memory Limit: 1000K
 
 You were just hired as CEO of the local junkyard.One of your jobs is dealing
 with the incoming trash and sorting it for recycling.The trash comes every day
 in n containers and each of these containers
 contains certain amount of each of the n types of trash.Given the amount of
 trash in the containers find the optimal way to sort the trash.Sorting the
 trash means putting every type of trash in separate container.Each of the given
 containers has infinite capacity.The effort for moving one unit of trash
 from container i to j is 1 if i != j otherwise it is 0.You are to minimize the
 total effort.
 
 Input
 The first line contains the number n (1 <= n <= 150), the rest of the input
 file contains the descriptions of the containers.The 1 + i-th line contains the
 desctiption of the i-th container the j-th amount (0 <= amount <= 100) on this
 line denotes the amount of the j-th type of trash in the i-th container.
 
 Output
 You should write the minimal effort that is required for sorting the trash.
 
 Sample Input
 4
 62 41 86 94
 73 58 11 12
 69 93 89 88
 81 40 69 13
 
 Sample Output
 650
 ---
  * Origin: FreeStyle (2:5026/49.84)
 
 

Вернуться к списку тем, сортированных по: возрастание даты  уменьшение даты  тема  автор 

 Тема:    Автор:    Дата:  
 Hungary Algorithm!   Grebnov Ilya   08 Apr 2003 17:51:40 
 Hungary Algorithm!   Evgenij Masherov   09 Apr 2003 09:58:19 
 Re: Hungary Algorithm!   Grebnov Ilya   09 Apr 2003 17:46:32 
 Re: Hungary Algorithm!   Grebnov Ilya   09 Apr 2003 19:33:36 
 Hungary Algorithm!   Mity Usanov   09 Apr 2003 22:15:37 
 Hungary Algorithm!   Evgenij Masherov   12 Apr 2003 10:52:10 
 Hungary Algorithm!   Mity Usanov   12 Apr 2003 22:44:42 
Архивное /ru.algorithms/34263e946c6c.html, оценка 2 из 5, голосов 10
Яндекс.Метрика
Valid HTML 4.01 Transitional