{"raw_statement":[{"iden":"problem statement","content":"It's now the season of TAKOYAKI FESTIVAL!\nThis year, $N$ takoyaki (a ball-shaped food with a piece of octopus inside) will be served. The _deliciousness_ of the $i$\\-th takoyaki is $d_i$.\nAs is commonly known, when you eat two takoyaki of deliciousness $x$ and $y$ together, you restore $x \\times y$ health points.\nThere are $\\frac{N \\times (N - 1)}{2}$ ways to choose two from the $N$ takoyaki served in the festival. For each of these choices, find the health points restored from eating the two takoyaki, then compute the sum of these $\\frac{N \\times (N - 1)}{2}$ values."},{"iden":"constraints","content":"*   All values in input are integers.\n*   $2 \\leq N \\leq 50$\n*   $0 \\leq d_i \\leq 100$"},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$N$\n$d_1$ $d_2$ $...$ $d_N$"},{"iden":"sample input 1","content":"3\n3 1 2"},{"iden":"sample output 1","content":"11\n\nThere are three possible choices:\n\n*   Eat the first and second takoyaki. You will restore $3$ health points.\n*   Eat the second and third takoyaki. You will restore $2$ health points.\n*   Eat the first and third takoyaki. You will restore $6$ health points.\n\nThe sum of these values is $11$."},{"iden":"sample input 2","content":"7\n5 0 7 8 3 3 2"},{"iden":"sample output 2","content":"312"}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}