message stringlengths 2 44.5k | message_type stringclasses 2
values | message_id int64 0 1 | conversation_id int64 42 109k | cluster float64 5 5 | __index_level_0__ int64 84 217k |
|---|---|---|---|---|---|
Provide a correct Python 3 solution for this coding contest problem.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the minimum value in $a_s, a_{s+1}, ..., a_t$.
Note that ... | instruction | 0 | 40,414 | 5 | 80,828 |
"Correct Solution:
```
import sys
readline = sys.stdin.readline
write = sys.stdout.write
N, Q = map(int, input().split())
INF = 2**31-1
LV = (N-1).bit_length()
N0 = 2**LV
data = [0]*(2*N0)
lazy = [0]*(2*N0)
def gindex(l, r):
L = l + N0; R = r + N0
lm = (L // (L & -L)) >> 1
rm = (R // (R & -R)) >> 1
w... | output | 1 | 40,414 | 5 | 80,829 |
Provide a correct Python 3 solution for this coding contest problem.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the minimum value in $a_s, a_{s+1}, ..., a_t$.
Note that ... | instruction | 0 | 40,415 | 5 | 80,830 |
"Correct Solution:
```
import sys
input = sys.stdin.readline
INF = 2**31 - 1
class StarrySkyTree:
def __init__(self, n):
LV = (n-1).bit_length()
self.N0 = 2 ** LV
self.data = [0] * (2*self.N0)
self.lazy = [0] * (2*self.N0)
def gindex(self, l, r):
L = l + self.N0; R ... | output | 1 | 40,415 | 5 | 80,831 |
Provide a correct Python 3 solution for this coding contest problem.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the minimum value in $a_s, a_{s+1}, ..., a_t$.
Note that ... | instruction | 0 | 40,416 | 5 | 80,832 |
"Correct Solution:
```
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, log2
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import asc... | output | 1 | 40,416 | 5 | 80,833 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,417 | 5 | 80,834 |
Yes | output | 1 | 40,417 | 5 | 80,835 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,418 | 5 | 80,836 |
Yes | output | 1 | 40,418 | 5 | 80,837 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,419 | 5 | 80,838 |
Yes | output | 1 | 40,419 | 5 | 80,839 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,420 | 5 | 80,840 |
Yes | output | 1 | 40,420 | 5 | 80,841 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,421 | 5 | 80,842 |
No | output | 1 | 40,421 | 5 | 80,843 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,422 | 5 | 80,844 |
No | output | 1 | 40,422 | 5 | 80,845 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Write a program which manipulates a sequence $A$ = {$a_0, a_1, ..., a_{n-1}$} with the following operations:
* $add(s, t, x)$ : add $x$ to $a_s, a_{s+1}, ..., a_t$.
* $find(s, t)$ : report the ... | instruction | 0 | 40,423 | 5 | 80,846 |
No | output | 1 | 40,423 | 5 | 80,847 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,631 | 5 | 81,262 |
Yes | output | 1 | 40,631 | 5 | 81,263 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,632 | 5 | 81,264 |
Yes | output | 1 | 40,632 | 5 | 81,265 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,633 | 5 | 81,266 |
Yes | output | 1 | 40,633 | 5 | 81,267 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,634 | 5 | 81,268 |
Yes | output | 1 | 40,634 | 5 | 81,269 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,635 | 5 | 81,270 |
No | output | 1 | 40,635 | 5 | 81,271 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,636 | 5 | 81,272 |
No | output | 1 | 40,636 | 5 | 81,273 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,637 | 5 | 81,274 |
No | output | 1 | 40,637 | 5 | 81,275 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
In order to celebrate Twice's 5th anniversary, Tzuyu and Sana decided to play a game.
Tzuyu gave Sana two integers a and b and a really important quest.
In order to complete the quest, Sana ha... | instruction | 0 | 40,638 | 5 | 81,276 |
No | output | 1 | 40,638 | 5 | 81,277 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Only a few know that Pan and Apollo weren't only battling for the title of the GOAT musician. A few millenniums later, they also challenged each other in math (or rather in fast calculations). T... | instruction | 0 | 40,639 | 5 | 81,278 |
No | output | 1 | 40,639 | 5 | 81,279 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Only a few know that Pan and Apollo weren't only battling for the title of the GOAT musician. A few millenniums later, they also challenged each other in math (or rather in fast calculations). T... | instruction | 0 | 40,640 | 5 | 81,280 |
No | output | 1 | 40,640 | 5 | 81,281 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Only a few know that Pan and Apollo weren't only battling for the title of the GOAT musician. A few millenniums later, they also challenged each other in math (or rather in fast calculations). T... | instruction | 0 | 40,641 | 5 | 81,282 |
No | output | 1 | 40,641 | 5 | 81,283 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Only a few know that Pan and Apollo weren't only battling for the title of the GOAT musician. A few millenniums later, they also challenged each other in math (or rather in fast calculations). T... | instruction | 0 | 40,642 | 5 | 81,284 |
No | output | 1 | 40,642 | 5 | 81,285 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,828 | 5 | 81,656 |
Yes | output | 1 | 40,828 | 5 | 81,657 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,829 | 5 | 81,658 |
Yes | output | 1 | 40,829 | 5 | 81,659 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,830 | 5 | 81,660 |
Yes | output | 1 | 40,830 | 5 | 81,661 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,831 | 5 | 81,662 |
Yes | output | 1 | 40,831 | 5 | 81,663 |
Evaluate the correctness of the submitted Python 2 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,832 | 5 | 81,664 |
Yes | output | 1 | 40,832 | 5 | 81,665 |
Evaluate the correctness of the submitted Python 2 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,833 | 5 | 81,666 |
No | output | 1 | 40,833 | 5 | 81,667 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,834 | 5 | 81,668 |
No | output | 1 | 40,834 | 5 | 81,669 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,835 | 5 | 81,670 |
No | output | 1 | 40,835 | 5 | 81,671 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,836 | 5 | 81,672 |
No | output | 1 | 40,836 | 5 | 81,673 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Two positive integers a and b have a sum of s and a bitwise XOR of x. How many possible values are there for the ordered pair (a, b)?
Input
The first line of the input contains two integers s ... | instruction | 0 | 40,837 | 5 | 81,674 |
No | output | 1 | 40,837 | 5 | 81,675 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,991 | 5 | 81,982 |
"Correct Solution:
```
a, b, c = map(int, input().split())
print("Yes" if ((c-a-b) > 0 and 4*a*b < (c-a-b)**2) else "No")
``` | output | 1 | 40,991 | 5 | 81,983 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,992 | 5 | 81,984 |
"Correct Solution:
```
a,b,c=map(int,input().split())
if 4*a*b<(c-a-b)**2 and c-a-b>=0:
print('Yes')
else:
print('No')
``` | output | 1 | 40,992 | 5 | 81,985 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,993 | 5 | 81,986 |
"Correct Solution:
```
a,b,c=map(int,input().split())
print(["No","Yes"][4*a*b<(c-a-b)**2 and c-a-b>0])
``` | output | 1 | 40,993 | 5 | 81,987 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,994 | 5 | 81,988 |
"Correct Solution:
```
a, b, c = map(int, input().split())
if 4*a*b < (c-a-b)**2 and (c-a-b) > 0:
print("Yes")
else:
print("No")
``` | output | 1 | 40,994 | 5 | 81,989 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,995 | 5 | 81,990 |
"Correct Solution:
```
a,b,c = [int(hoge) for hoge in input().split()]
print("NYoe s"[4*a*b < (c-a-b)**2 and a+b<c::2])
``` | output | 1 | 40,995 | 5 | 81,991 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,996 | 5 | 81,992 |
"Correct Solution:
```
a,b,c=map(int, input().split())
r=c-a-b
if r > 0 and r**2>4*a*b:
print("Yes")
else:
print("No")
``` | output | 1 | 40,996 | 5 | 81,993 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,997 | 5 | 81,994 |
"Correct Solution:
```
a,b,c = map(int,input().split())
print('Yes' if c-b-a>0 and 0<(c-a-b)**2-4*a*b else 'No')
``` | output | 1 | 40,997 | 5 | 81,995 |
Provide a correct Python 3 solution for this coding contest problem.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b \ c
Output
If \sqrt{a} + \sqrt{b} < \sqrt{c}, print ... | instruction | 0 | 40,998 | 5 | 81,996 |
"Correct Solution:
```
a,b,c=map(int,input().split())
if c>=a+b and 4*a*b<(c-a-b)**2:
print('Yes')
else:
print('No')
``` | output | 1 | 40,998 | 5 | 81,997 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 40,999 | 5 | 81,998 |
Yes | output | 1 | 40,999 | 5 | 81,999 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,000 | 5 | 82,000 |
Yes | output | 1 | 41,000 | 5 | 82,001 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,001 | 5 | 82,002 |
Yes | output | 1 | 41,001 | 5 | 82,003 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,002 | 5 | 82,004 |
Yes | output | 1 | 41,002 | 5 | 82,005 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,003 | 5 | 82,006 |
No | output | 1 | 41,003 | 5 | 82,007 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,004 | 5 | 82,008 |
No | output | 1 | 41,004 | 5 | 82,009 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,005 | 5 | 82,010 |
No | output | 1 | 41,005 | 5 | 82,011 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Does \sqrt{a} + \sqrt{b} < \sqrt{c} hold?
Constraints
* 1 \leq a, b, c \leq 10^9
* All values in input are integers.
Input
Input is given from Standard Input in the following format:
a \ b... | instruction | 0 | 41,006 | 5 | 82,012 |
No | output | 1 | 41,006 | 5 | 82,013 |
Provide a correct Python 3 solution for this coding contest problem.
We have N weights indexed 1 to N. The mass of the weight indexed i is W_i.
We will divide these weights into two groups: the weights with indices not greater than T, and those with indices greater than T, for some integer 1 \leq T < N. Let S_1 be t... | instruction | 0 | 41,015 | 5 | 82,030 |
"Correct Solution:
```
n = int(input())
l = list(map(int, input().split()))
print(min([abs(sum(l[0:i]) - sum(l[i:])) for i in range(1, len(l))]))
``` | output | 1 | 41,015 | 5 | 82,031 |
Provide a correct Python 3 solution for this coding contest problem.
We have N weights indexed 1 to N. The mass of the weight indexed i is W_i.
We will divide these weights into two groups: the weights with indices not greater than T, and those with indices greater than T, for some integer 1 \leq T < N. Let S_1 be t... | instruction | 0 | 41,016 | 5 | 82,032 |
"Correct Solution:
```
input()
l=list(map(int,input().split()))
s=sum(l)
a,t=s,0
for i in l: t+=i; a=min(a,abs(s-t*2))
print(a)
``` | output | 1 | 41,016 | 5 | 82,033 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.