{"raw_statement":[{"iden":"statement","content":"You are given an array of _n_ integer numbers. Let _sum_(_l_, _r_) be the sum of all numbers on positions from _l_ to _r_ non-inclusive (_l_\\-th element is counted, _r_\\-th element is not counted). For indices _l_ and _r_ holds 0 ≤ _l_ ≤ _r_ ≤ _n_. Indices in array are numbered from 0.\n\nFor example, if _a_ = \\[ - 5, 3, 9, 4\\], then _sum_(0, 1) =  - 5, _sum_(0, 2) =  - 2, _sum_(1, 4) = 16 and _sum_(_i_, _i_) = 0 for each _i_ from 0 to 4.\n\nChoose the indices of three delimiters _delim_0, _delim_1, _delim_2 (0 ≤ _delim_0 ≤ _delim_1 ≤ _delim_2 ≤ _n_) and divide the array in such a way that the value of _res_ = _sum_(0, _delim_0) - _sum_(_delim_0, _delim_1) + _sum_(_delim_1, _delim_2) - _sum_(_delim_2, _n_) is maximal.\n\nNote that some of the expressions _sum_(_l_, _r_) can correspond to empty segments (if _l_ = _r_ for some segment)."},{"iden":"input","content":"The first line contains one integer number _n_ (1 ≤ _n_ ≤ 5000).\n\nThe second line contains _n_ numbers _a_0, _a_1, ..., _a__n_ - 1 ( - 109 ≤ _a__i_ ≤ 109)."},{"iden":"output","content":"Choose three indices so that the value of _res_ is maximal. If there are multiple answers, print any of them."},{"iden":"examples","content":"Input\n\n3\n-1 2 3\n\nOutput\n\n0 1 3\n\nInput\n\n4\n0 0 -1 0\n\nOutput\n\n0 0 0\n\nInput\n\n1\n10000\n\nOutput\n\n1 1 1"}],"translated_statement":null,"sample_group":[],"show_order":[],"formal_statement":null,"simple_statement":null,"has_page_source":false}