CodeBus
www.codebus.net
Search
Sign in
Sign up
Hot Search :
Source
embeded
web
remote control
p2p
game
More...
Location :
Home
Search - Office m
Main Category
SourceCode
Documents
Books
WEB Code
Develop Tools
Other resource
Sub Category
Compress-Decompress algrithms
STL
Data structs
Algorithm
AI-NN-PR
matlab
Bio-Recognize
Crypt_Decrypt algrithms
mathematica
Maple
DataMining
Big Data
comsol
physical calculation
chemical calculation
simulation modeling
Search - Office m - List
[
Data structs
]
Seat-adjustment
DL : 0
题目描述: 百度办公区里到处摆放着各种各样的零食。百度人力资源部的调研发现,员工如果可以在自己喜欢的美食旁边工作,工作效率会大大提高。因此,百度决定进行一次员工座位的大调整。 调整的方法如下: 1 . 首先将办公区按照各种零食的摆放分成 N 个不同的区域。(例如:可乐区,饼干区,牛奶区等等)。 2 . 每个员工对不同的零食区域有不同的喜好程度(喜好程度度的范围为 1 — 100 的整数, 喜好程度越大表示该员工越希望被调整到相应的零食区域)。 3 . 由于每个零食区域可以容纳的员工数量有限,人力资源部希望找到一个最优的调整方案令到总的喜好程度最大。 输入: 第一行包含两个整数 N , M ,( 1<=N , M<=300 )。分别表示 N 个区域和 M 个员工。 第二行是 N 个整数构成的数列 a ,其中 a[i] 表示第 i 个区域可以容纳的员工数, (1<=a[i]<=M , a[1]+a[2]+..+a[N]=M) 。 紧接着是一个 M*N 的矩阵 P , P ( i , j )表示第 i 个员工对第 j 个区域的喜好度。 输出: 对于每个测试数据,输出可以达到的最大的喜好程度。 -Title Description: Baidu placed everywhere office area with a variety of snacks. Baidu HR survey found that employees can work in the next if their favorite food, work efficiency will be greatly improved. Thus , Baidu adjusted once the staff decided to conduct large seat . The method of adjustment is as follows: 1 . First, the office area in a variety of snacks placed into N different regions. ( E.g. : Coke zone , zone biscuits , milk, region , etc.). 2 . Each employee of the different regions have different preferences snacks degree ( degree of preference in the range of 1 degree- integer 100, the greater the degree of preference expressed hope that more staff be adjusted to the appropriate snack area ) . 3 . Due to the limited number of employees in each area can accommodate snacks , HR hoping to find an optimal solution to make adjustments to the maximum total degree of preference . Input: The first line contains two integers N, M, (1 <= N, M <= 300). N regions , r
Date
: 2025-12-30
Size
: 1kb
User
:
qiang22
CodeBus
is one of the largest source code repositories on the Internet!
Contact us :
1999-2046
CodeBus
All Rights Reserved.