×

# codeforces educational round

 0 could anyone suggest a simpler stategy for solving the problem:http://codeforces.com/contest/863/problem/B asked 21 Sep '17, 23:22 183●8 accept rate: 14%

 1 Just brute-force it, since $N$ is very small. ($N<= 50$) answered 21 Sep '17, 23:50 6★bazsi700 375●8 accept rate: 7%
 1 You can use 2D DP and Sorting. Here is link to my solution. At any point, you can choose to find the difference between adjacent numbers or you can leave it.You must remember that you can leave atmost 2 numbers. answered 22 Sep '17, 11:35 5★anushi 246●1●7 accept rate: 15%
 0 @viralivora You need to minimize total instability, so, firstly sort the array with respect to weight of person. Now traverse this sorted array to find the maximum absolute difference between two consequtive people. These two people will sit on single kayaks.(No contribution to instability.) And remaining people will be divided in groups of two. (Note : These groups will be consecutive divisions of two people each ,from the same array excluding the ones alloted with single kayaks.) So, the sum of the absolute difference of their weights of each group is the required total instability. answered 22 Sep '17, 00:03 96●6 accept rate: 14%
 toggle preview community wiki:
Preview

By Email:

Markdown Basics

• *italic* or _italic_
• **bold** or __bold__
• image?![alt text](/path/img.jpg "title")
• numbered list: 1. Foo 2. Bar
• to add a line break simply add two spaces to where you would like the new line to be.
• basic HTML tags are also supported
• mathemetical formulas in Latex between \$ symbol

Question tags:

×2,403
×594
×283

question asked: 21 Sep '17, 23:22

question was seen: 318 times

last updated: 22 Sep '17, 11:35