{"problem":{"name":"Pizza","description":{"content":"We have a circular pizza.   Takahashi will cut this pizza using a sequence $A$ of length $N$, according to the following procedure. *   First, make a cut from the center in the $12$ o'clock direction","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc238_b"},"statements":[{"statement_type":"Markdown","content":"We have a circular pizza.  \nTakahashi will cut this pizza using a sequence $A$ of length $N$, according to the following procedure.\n\n*   First, make a cut from the center in the $12$ o'clock direction.\n*   Next, do $N$ operations. The $i$\\-th operation is as follows.\n    *   Rotate the pizza $A_i$ degrees clockwise.\n    *   Then, make a cut from the center in the $12$ o'clock direction.\n\nFor example, if $A=(90,180,45,195)$, the procedure cuts the pizza as follows.\n![image](https://img.atcoder.jp/ghi/AWP_pict.png)\nFind the center angle of the largest pizza after the procedure.\n\n## Constraints\n\n*   All values in input are integers.\n*   $1 \\le N \\le 359$\n*   $1 \\le A_i \\le 359$\n*   There will be no multiple cuts at the same position.\n\n## Input\n\nInput is given from Standard Input in the following format:\n\n$N$\n$A_1$ $A_2$ $\\dots$ $A_N$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc238_b","tags":[],"sample_group":[["4\n90 180 45 195","120\n\nThis input coincides with the example in the Problem Statement.  \nThe center angle of the largest pizza is $120$ degrees."],["1\n1","359"],["10\n215 137 320 339 341 41 44 18 241 149","170"]],"created_at":"2026-03-03 11:01:14"}}