Skip to content

Commit

Permalink
Update Readme.md
Browse files Browse the repository at this point in the history
  • Loading branch information
wisdompeak authored Jun 24, 2019
1 parent bdc1327 commit b4e6214
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Priority_Queue/621.Task-Scheduler/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,5 @@
最后我们把这些容器并列排成一排,再加上落单的那些可以再摆放一排,就是我们的解决方案.

这些容器有多少个位置呢?注意到,这些容器都是均匀填充的,即任意两个容器之间的个数不会相差大于1(把idle也算上),所以无非就是两种情况,一种就是这些容器(至少部分容器)还没有填充满n个,所以我们需要的位置依然是整个矩阵的大小加上落单的个数```(maxFreq-1)*n+count```.另外一种就是这些容器都已经填充满n个了,说明没有任何需要用idle来占位的情况,那么我们需要的位置的个数就是字符的个数```tasks.size()```

与本题类似的题目还有:767. Reorganize String,1054. Distant Barcodes

0 comments on commit b4e6214

Please sign in to comment.