摘要:
Problem D: The NecklaceMy little sister had a beautiful necklace made of colorful beads. Two successive beads in the necklace shared a common color at their meeting point. The figure below shows a segment of the necklace:But, alas! One day, the necklace was torn and the beads were all scattered ove. 阅读全文
摘要:
Given a sequence of integers, a1, a2,..., an , we define its sign matrix S such that, for 1ijn , Sij = `` + " if ai +...+ aj > 0 ; Sij = `` - " if ai +...+ aj #include#include#include#include#include#include#include#include#include#include#include#includeusing namespace std;#define MAX_ 阅读全文