Problem:


Score : 100 points

Problem Statement

Snuke has N integers: 1,2,\ldots,N.
He will choose K of them and give those to Takahashi.

How many ways are there to choose K consecutive integers?

Constraints

All values in input are integers.

1 \leq K \leq N \leq 50

Input

Input is given from Standard Input in the following format:

N K

Output

Print the answer.

Sample Input 1

3 2

Sample Output 1

2

There are two ways to choose two consecutive integers: (1,2) and (2,3).

Sample Input 2

13 3

Sample Output 2

11



Sample input:
3 2


Sample output:
2

Submission status: Accepted

Solution code:
n,r = map(int,input().split())
print(n-r+1)

Submission status: Accepted

Solution code:
n,k=map(int, input().split())  #複数数値入力

seq = n - k +1
print(seq)

Submission status: Accepted

Solution code:
N,K = map(int,input().rstrip().split(' '))

count = 0
flag = 0

for i in range(N):
    flag = 0
    for j in range(K):
        if i + j < N:
            pass
        else:
            flag = 1

    if flag == 0:
        count += 1
    else:
        break

print(count)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())

# bunsi = 1
# bunbo = 1
# for i in range(k):
#     bunsi = bunsi * (n - i)
#     bunbo = bunbo * (i+1)
    
print(n-k+1)

Submission status: Accepted

Solution code:
x,y = map(int,input().split())
count = 0
while count+y <= x:
  count += 1

print(count)

Submission status: Accepted

Solution code:
m=list(map(int, input().strip().split()))
print(m[0]-m[1]+1)

Submission status: Accepted

Solution code:
[n, k] = [int(i) for i in input().split()]

print(n - k + 1)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

def main():
	n, k = map(int, input().split())
	print(n-k+1)

if __name__ == '__main__':
	import sys
	sys.exit(main())

Submission status: Accepted

Solution code:
n,k = map(int, input().split())
print(n - k + 1)

Submission status: Accepted

Solution code:
parents = list(map(int,input().split(' ')))
print(parents[0] - parents[1] + 1)

Submission status: Accepted

Solution code:
n, k = (int(i) for i in input().split())  
print(n+1-k)

Submission status: Accepted

Solution code:
n, k = (int(_) for _ in input().split())
print(n - k + 1)

Submission status: Accepted

Solution code:
a, b = input().split()
print(int(a) - int(b) + 1)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())

ans = n - k + 1

print(ans)

Submission status: Accepted

Solution code:
a,b = list(map(int,input().split()))
print(a+1-b)

Submission status: Accepted

Solution code:
a = raw_input().split()
print(int(a[0])-int(a[1])+1)

Submission status: Accepted

Solution code:

def solve():
    N, K = map(int, input().split())
    print(N - K + 1)


if __name__ == '__main__':
    solve()

Submission status: Accepted

Solution code:
def main():
	N, K = map(int, input().split())
	print(N-K+1)


if __name__ == '__main__':
	main()

Submission status: Accepted

Solution code:
from sys import stdin

def main():
    n,k = [int(x) for x in stdin.readline().rstrip().split()]
    ans = n - k + 1
    print(ans)
    
if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
count = N - K + 1
print(count)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# input
#a = int(input())
#a,b = input()
a, b = map(int, input().split())
#a, b, c = input().split()
print(a-b+1)

Submission status: Accepted

Solution code:
N,K=(int(x) for x in input().split())
print(N-K+1)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())

ans = n-(k-1)

print(ans)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

# スペース区切りの整数の入力
a, b = map(int, input().split())

# 出力
print(a-b+1)

Submission status: Accepted

Solution code:
S = input().split()
print(int(S[0])-int(S[1])+1)

Submission status: Accepted

Solution code:
N,K = map(int, input().split())

print(N-K+1)

Submission status: Accepted

Solution code:
N, K = (int (x) for x in input().split())
print(N-K+1)

Submission status: Accepted

Solution code:
l = list(map(int, input().split()))
print(l[0]-l[1]+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

print(N-K+1);

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

N, K = map(int, input().rstrip().split())

print(N-K+1)

Submission status: Accepted

Solution code:
#!/usr/bin/env python
# -*- coding: utf-8 -*-


def main():
  n, k = map(int, input().split())

  print(n - k + 1)


if __name__ == '__main__':
  main()

Submission status: Accepted

Solution code:
a,b=map(int,raw_input().split())
print a-b+1

Submission status: Accepted

Solution code:
N, K = list(map(int, input().split()))

if N < K:
    print(0)
    exit(0)
print(N - K + 1)

Submission status: Accepted

Solution code:
N, K = (int(i) for i in input().split())
if N < K:
    ans = 0
else:
    ans = N - K+1
print("{}".format(ans))

Submission status: Accepted

Solution code:
raw =  input().split()
N = int(raw[0])
K = int(raw[1])
ans = N -  K +1
print(ans)

Submission status: Accepted

Solution code:
N,K=map(int,input().split())

if K > N :
  print(0)
elif K == N:
  print(1)
else:
  print(N - K + 1)

Submission status: Accepted

Solution code:
a = [int(x) for x in input().split(" ")]
print(a[0] - a[1] + 1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
S = N - K + 1
print(S)

Submission status: Accepted

Solution code:
N, K = [int(a) for a in input().split()]
print(N-K+1)

Submission status: Accepted

Solution code:
N, K= map(int,input().split())

print(N - K + 1)

Submission status: Accepted

Solution code:
A = list(map(int,input().split()))
print(A[0]-A[1]+1)

Submission status: Accepted

Solution code:
n,k = map(int, input().split())

print(n+1-k)

Submission status: Accepted

Solution code:
n, k = [int(x) for x in input().split()]

print(n - k + 1)

Submission status: Accepted

Solution code:
a = map(int,input().split())
a = list(a)
b = a[0] - a[1] +1
print(b)

Submission status: Accepted

Solution code:
N, K = input().split()
X = int(N)-int(K)+1
print(X)

Submission status: Accepted

Solution code:
n,k=list(map(int,input().split()))
print(n-k+1)

Submission status: Accepted

Solution code:
data = input().split()
n = int(data[0])
k = int(data[1])

print(n - k  +1)

Submission status: Accepted

Solution code:
import sys

if __name__ == "__main__":
	s = input().split(" ")
	print(int(s[0]) - (int(s[1]) - 1))

Submission status: Accepted

Solution code:
N,K=map(int,input().split())


print(N-K+1)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
print(a - b + 1)

Submission status: Accepted

Solution code:
n,j =map(int,input().split())

print(n-j+1)

Submission status: Accepted

Solution code:
N, K = [int(i) for i in input().split()]

ans = N - (K - 1)

print(ans)

Submission status: Accepted

Solution code:
n,k=map(int,input().split());print(n-(k-1))

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

N, K = [int(x) for x in input().split()]

print(N-K+1)

Submission status: Accepted

Solution code:
l = map(int,raw_input().split())
print 1+l[0]-l[1]

Submission status: Accepted

Solution code:
nk = [int(i) for i in input().split() ]
print (nk[0] - nk[1] + 1)

Submission status: Accepted

Solution code:
n ,k = map(int,input().split())
print(n-k+1)

Submission status: Accepted

Solution code:
N,K=map(int,input().split());print(N-K+1)

Submission status: Accepted

Solution code:
import sys

N, K = input().split()
print(int(N)-int(K)+1)

Submission status: Accepted

Solution code:
from sys import stdin
input=input=stdin.readline().rstrip().split()
for i in range(len(input)):
  input[i]=int(input[i])
#print(input)

output=input[0]-(input[1]-1)
print(output)

Submission status: Accepted

Solution code:
# input
N, K = map(int, input().split())

print(N-K+1)

Submission status: Accepted

Solution code:
a, b =(int(x) for x in input().split())
print(a-b+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().strip().split())

print(N - K + 1)

Submission status: Accepted

Solution code:

data = list(map(int, input().split()))

N = data[0]
K = data[1]

print(N - K + 1)

Submission status: Accepted

Solution code:
from io import StringIO
from collections import *
from functools import *
import sys


def main(inputs):
    #n = int(next(inputs))
    # xs = list(map(int, next(inputs).split()))
    n, k = map(int, next(inputs).split())
    return n - k + 1


def gen_inputs(str_=None):
    inputs = StringIO(str_) if str_ else sys.stdin
    while True:
        a = inputs.readline().rstrip()
        yield a
        pass
    pass


if __name__ == "__main__":
    print(main(gen_inputs()))
    pass

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

n, k = map(int, input().split())

ans = n-(k-1)
print(ans)

Submission status: Accepted

Solution code:

n, k = map(int, input().split())

count = n - k +1
print(count)

Submission status: Accepted

Solution code:
line=input().split(" ")
n=int(line[0])
k=int(line[1])
print(n-k+1)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
ans = 0
for i in range(n):
    if i + k - 1 < n:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
#A
import numpy as np
import math
import re

n,k = list(map(int,re.split(" ",input())))

count = 0
for i in range(n-k+1):
    count += 1

print(count)

Submission status: Accepted

Solution code:
N,K = map(int, input().split())

print(N - K + 1)

Submission status: Accepted

Solution code:

n, k = map(int,input().split())

print(n-k+1)

Submission status: Accepted

Solution code:
n, k = map(int,input().split())

print(n - k + 1)

Submission status: Accepted

Solution code:
x,y = map(int,input().split())
print( x - y + 1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

# def fac(N):
#     if N <= 1: return 1
#     else: return N * fac(N-1)

# ans = fac(N) // fac(N-K) // fac(K)
# print(ans)
print(N-K+1)

Submission status: Accepted

Solution code:
N,K=map(int, input().split())
x = N - K +1
print(x)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

def solve():
  N, K = map(int, input().split())
  return str(N-K+1)

if __name__ == '__main__':
    print(solve())

Submission status: Accepted

Solution code:
nk = input()

n = int(nk.split(' ')[0])
k = int(nk.split(' ')[1])

answer = n - k + 1
print(answer)

Submission status: Accepted

Solution code:
n,k = map(int,input().split())

print(n - k + 1)

Submission status: Accepted

Solution code:
N,K = map(int, input().split())

print (N-K+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
print((N-K+1))

Submission status: Accepted

Solution code:
n, k = map(int, input().split())

print(n+1-k)

Submission status: Accepted

Solution code:
import numpy as np
n,k = map(int, input().split())
print(n-k+1)

Submission status: Accepted

Solution code:
n, k = map(int,input().split())
print(n - k + 1)

Submission status: Accepted

Solution code:
# coding:utf-8

import math
import re

def main(params):
    n,k = params[0].split()
    print int(n) - int(k) + 1
    return int(n) - int(k) + 1

if __name__ == "__main__":
    cnt = 1 # TODO: edit here
    params = []
    for i in range(cnt):
        param = raw_input()
        params.append(param)
    main(params)

Submission status: Accepted

Solution code:
#python 3.5.2

n, k = [int(s) for s in input().split()]

print(n - (k - 1))

Submission status: Accepted

Solution code:
#!/usr/bin/env pypy3

import math, itertools, operator
from math import *
from math import factorial as fact
from itertools import permutations, combinations
from functools import reduce
from statistics import mean, median, median_low, median_high, mode
# Before Python 3.5
from fractions import gcd

#import numpy
#import scipy, scipy.special
#from sympy import isprime, nextprime
#from sympy.ntheory import factorint

inf = float('inf')

def lcm(a, b):
    return a * b // gcd(a,b)

def perm(a, b):
    import scipy.special
    return scipy.special.perm(a, b, exact = True)

def comb(a, b):
    import scipy.special
    return scipy.special.comb(a, b, exact = True)

def dfact(n):
    import scipy.special
    return scipy.special.factorial2(n, exact = True)

def prod(l):
    return reduce(operator.mul, l)

def input_ints(inp = input, sep = ' ', conv = int):
    return map(conv, inp().split(sep = sep))

################################################################################


N, K = input_ints()

print(N-K+1)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())

print(a-b +1)

Submission status: Accepted

Solution code:
n,k = map(int,input().split())

ans = n - k + 1

print(ans)

Submission status: Accepted

Solution code:
n,k=list(map(int,input().split()))

print(n-k+1)

Submission status: Accepted

Solution code:
N,K= input().split()
print(int(N)-int(K)+1)

Submission status: Accepted

Solution code:
import sys
stdin = sys.stdin

sys.setrecursionlimit(10 ** 7)

def li(): return map(int, stdin.readline().split())
def li_(): return map(lambda x: int(x) - 1, stdin.readline().split())
def lf(): return map(float, stdin.readline().split())
def ls(): return stdin.readline().split()
def ns(): return stdin.readline().rstrip()
def lc(): return list(ns())
def ni(): return int(stdin.readline())
def nf(): return float(stdin.readline())

n,k = li()
print(n-k+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

ans = N - K + 1
print(ans)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())

ans = 0
for i in range(a):
    if i + b > a:
        break
    else:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
# coding: utf-8

import sys
input = sys.stdin.readline

# N = int(input())
# L = list(map(int, input().split()))
N, K = map(int, input().split())
# S = input()

print(N - (K - 1))

Submission status: Accepted

Solution code:
import bisect
import numpy as np
import scipy as sp
from sys import stdin

n, k = map(int, input().split())
print(n - k + 1)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Tue Feb 26 17:52:43 2019

@author: nakamuratakayuki
"""

N,K = tuple(map(int,input().split()))
print(N-K+1)

Submission status: Accepted

Solution code:
#coding:utf-8

N_, K_ = list(map(int, input().split()))
print(N_ - K_ + 1)

Submission status: Accepted

Solution code:
h = list(map(int, input().split()))



print(h[0]-h[1]+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())			# "5 7" -> ["5", "7"] -> 5, 7 => N=5,K=7

print(N-K+1)

Submission status: Accepted

Solution code:
#N = int(input())
#L = list(map(int, input()))
A, B = map(int, input().split())
print(A - B + 1)

Submission status: Accepted

Solution code:
a,b = [int(i) for i in input().split()]

print(a - b + 1)

Submission status: Accepted

Solution code:
n,k=map(int,input().split())

print(n-k+1)

Submission status: Accepted

Solution code:
N,K=[int(i) for i in input().split(" ")]
print(N-K+1)

Submission status: Accepted

Solution code:
inp = input()
N = int(inp.split()[0])
K = int(inp.split()[1])

print(N - K + 1)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import sys

debug = False

def log(text):
    if debug:
        print(text)

def parse_input(lines_as_string = None):

    global debug
    lines = []
    if lines_as_string is None:
        debug = False
        lines.append(input())
    else:
        debug = True
        lines = [e for e in lines_as_string.split("\n")][1:-1]


    token = lines[0].split()
    n = int(token[0])
    k = int(token[1])

    return (n, k)


def solve(n, k):


    return n - k + 1


def main():
    # 出力

    print("%s" % solve(*parse_input()))

if __name__ == '__main__':

    main()

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
print(N + 1 - K)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""
Created on Sat May 11 20:51:09 2019

@author: owner
"""

N, k = map(int, input().split())

print('{}'.format(N-(k-1)))

Submission status: Accepted

Solution code:
def main():
    N,K=list(map(int,input().split(' ')))
    print (N-K+1)

if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
N,K=[int(i) for i in input().split()]
print(N-K+1)

Submission status: Accepted

Solution code:
import sys

readline = sys.stdin.readline

N, K = map(int, readline().split())

ret = N - K + 1

print(ret)

Submission status: Accepted

Solution code:
n,k = [int(u) for u in input().split(" ")]
print(n-k+1)

Submission status: Accepted

Solution code:
N, K = list(map(int, input().split()))
print(N-K+1)

Submission status: Accepted

Solution code:
#d=["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
#import numpy as np
#n=int(input())
#li=input().split()
#S=input()
#import fractions
#n=int(input())

lis=list(map(int,input().split()))
ans=lis[0]-lis[1]+1


print(ans)

Submission status: Accepted

Solution code:
N,K = map(int,input().split())
ans = N-K+1
print(ans)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
# n=3
# k=2
print(n-k+1)

Submission status: Accepted

Solution code:
n, m = input().split()
N = int(n)
K = int(m)

print(N - K + 1)

Submission status: Accepted

Solution code:
import sys
range = xrange
input = raw_input

n, k = [int(x) for x in input().split()]

print n-k + 1

Submission status: Accepted

Solution code:
n , k = map ( int , input ().split())
ans = n - k + 1
print ( ans)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
cnt = 0
for i in range(n):
    if i + k >= n:
        print(cnt+1)
        break
    else:
        cnt += 1

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

ret = N - K + 1
print(ret)

Submission status: Accepted

Solution code:
N,K = map(int,input().split())
print(N-K+1)

Submission status: Accepted

Solution code:
N,K = map(int,input().split())

count = 0
for i in range(N-K+1):
    count += 1

print(count)

Submission status: Accepted

Solution code:
## 計算量が(10^6)^2あるから絶対TLEなるけど

from sys import stdin
import numpy as np
 
N, K = map(int,input().split())
ans = N - K + 1

print(ans)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

res = 0
for i in range(N-K+1):
    res += 1
    
print(res)

Submission status: Accepted

Solution code:
a,b= input().split()
N = int(a)
K = int(b)
print(N-K+1)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

count = 0
for i in range(1, a + 1):
    if a >= i + b - 1:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N, K  = map(int, input().split())
print(N-K+1)

Submission status: Accepted

Solution code:
n,k=map(int,input().split())
print(max(0,n-k+1))

Submission status: Accepted

Solution code:
N, M = map(int, input().split())
print(N-M+1)

Submission status: Accepted

Solution code:
n,k = map(int,input().split())
ans = n - k  + 1
print(ans)

Submission status: Accepted

Solution code:
N,K = map( int, input().split())
print(N-K+1)

Submission status: Accepted

Solution code:
N,K = [int(x) for x in input().split()]

print(N-K+1)

Submission status: Accepted

Solution code:
k, n = map(int, input().split())
print(k-n+1)

Submission status: Accepted

Solution code:
N,K = map(int,input().split())

print("{0}".format(N-K+1))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys


def solve(N: int, K: int):
    ret = N - K + 1
    print(ret)
    return


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    N = int(next(tokens))  # type: int
    K = int(next(tokens))  # type: int
    solve(N, K)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

print(N-K+1)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
from collections.abc import Iterable
from math import *
from itertools import *
from collections import *
from functools import *
from operator import *
try:
    from math import gcd
except Exception:
    from fractions import gcd


def solve(N: int, K: int):
    return N - (K - 1)


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    N = int(next(tokens))  # type: int
    K = int(next(tokens))  # type: int
    result = solve(N, K)
    if isinstance(result, Iterable):
        result = '\n'.join([str(v) for v in result])
    print(result)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n, k = map(int, input().split())

print(n-k+1)

Submission status: Accepted

Solution code:
from math import factorial
n,k = map(int, input().strip().split())

print(max(0, n-k+1))

Submission status: Accepted

Solution code:
N, K = map(int, input().split(' '))
print(N - (K -1))

Submission status: Accepted

Solution code:
N, K = input().split()

answer = int(N) - int(K) + 1

print(answer)

Submission status: Accepted

Solution code:
n, k = list(map(int, input().split()))

print(n - k + 1)

Submission status: Accepted

Solution code:
if __name__ == '__main__':
    import sys
    input = sys.stdin.readline

    n, k = map(int, input().split())
    print(n-k+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split()) 
print(N-K+1)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
N, K = map(int, input().split())
print(N - K + 1)

Submission status: Accepted

Solution code:
n,k=map(int, input().split())

print(n-k+1)

Submission status: Accepted

Solution code:
x = input().split()
N = int(x[0])
K = int(x[1])

S = N - K + 1
print(str(S))

Submission status: Accepted

Solution code:
n, k = [int(item) for item in input().split()]

print(n-k+1)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
import sys
import math
from bisect import bisect_left
from bisect import bisect_right
import collections
import copy
input = sys.stdin.readline
 
# bisect_left(lists, 3)
# bisect_right(lists, 3)
 
def main():
	N, K = map(int, input().split(" "))
	
	ans = N - K + 1

	print(ans)

	
	
if __name__ == "__main__":
	main()

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
ans = N - K + 1
print(ans)

Submission status: Accepted

Solution code:
N,K = map(int, input().split())
print(N+1-K)

Submission status: Accepted

Solution code:
N, K = [int(x) for x in input().split()]

print(N - K + 1)

Submission status: Accepted

Solution code:
n, m = map(int, input().split())
print(n - m + 1)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
n, k = map(int, input().split())
print(n-k+1)

Submission status: Accepted

Solution code:
a,b= map(int, input().split())
print(a-b+1)

Submission status: Accepted

Solution code:
n, k = input().split()

n = int(n)
k = int(k)

n_patterns = n - k + 1

if n_patterns <= 0:
    n_patterns = 0

print(n_patterns)

Submission status: Accepted

Solution code:
N,K = map(int,input().split())
print(int(N-K+1))

Submission status: Accepted

Solution code:
n, k = [int(_) for _ in input().split()]
print(n - k + 1)

Submission status: Accepted

Solution code:
line = [int(x) for x in input().split(" ")]
print(line[0] - line[1] + 1)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
print("{}".format(n - k + 1))

Submission status: Accepted

Solution code:
#input
a = list(map(int,input().split())) #input from array of integer like "1 2 3"

print(a[0]-a[1]+1)

Submission status: Accepted

Solution code:
n, k=map(int, input().split())
result=n-(k-1)
print(result)

Submission status: Accepted

Solution code:
N,K = [int(x) for x in input().split()]

print(N-K+1)

Submission status: Accepted

Solution code:
MAX_INT = int(10e10)
def IL(): return list(map(int,input().split()))
def SL(): return input().split()
def I(): return int(sys.stdin.readline())
def S(): return input()

def combi(a,b):
    C = 1
    for j in range(b):
        C = C*(a-j)//(j+1)
    return C

N,K = IL()

print(N-K+1)

Submission status: Accepted

Solution code:
N,K = map(int, raw_input().split())
print(N-K+1)

Submission status: Accepted

Solution code:
N, K = [int(c) for c in input().split()]
print(N-K+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
ans = N - K + 1
print(ans)

Submission status: Accepted

Solution code:
N, K = map(int, input().split(" "))

print(N - K + 1)

Submission status: Accepted

Solution code:
nums = list(map(int, input().split()))
N, K = nums[0], nums[1]
print(N-K+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split(" "))

ans = N - K + 1


print(ans)

Submission status: Accepted

Solution code:
# -*- coding:utf-8 -*-

def solve():
    N, K = list(map(int, input().split()))

    print(N-K+1)

if __name__ == "__main__":
    solve()

Submission status: Accepted

Solution code:
N,Y=[int(i) for i in input().split()]
print(N-Y+1)

Submission status: Accepted

Solution code:
import sys
rr = lambda: sys.stdin.readline().strip()
ri = lambda: int(rr())
rs = lambda: [int(_) for _ in rr().split()]

N, K = rs()
ans = 0

print(N-K+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())
print(max(0, N - K + 1))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
n, k = map(int, input().split())
print(n - k + 1)

Submission status: Accepted

Solution code:
input = input().split()
N = int(input[0])
K = int(input[1])

print(N-K+1)

Submission status: Accepted

Solution code:
l = list(map(int,input().split(" ")))
temp = l[0] - l[1] + 1
print(temp)

Submission status: Accepted

Solution code:
N,K = (int(i) for i in input().split())

ans = N - (K-1)
print(ans)

Submission status: Accepted

Solution code:
N, K = input().strip().split()
N = int(N)
K = int(K)
print(N - K + 1)

Submission status: Accepted

Solution code:
p1, p2 = map(int, input().split())
print(p1-p2+1)

Submission status: Accepted

Solution code:
import sys

n, k = list(map(int, sys.stdin.readline().strip().split(" ")))

print(n-k+1)

Submission status: Accepted

Solution code:
import numpy as np
import statistics

n, k = (int(i) for i in input().split())  

print(n - k + 1)

Submission status: Accepted

Solution code:
N,K = list(map(int,input().rstrip().split()))

print(N-K+1)

Submission status: Accepted

Solution code:
n, k = [int(x) for x in input().split()]
print(n-k+1)

Submission status: Accepted

Solution code:
#A
N, K= map(int, input().split())
print(N - K + 1)

Submission status: Accepted

Solution code:
import sys

def main():
    input = sys.stdin.readline
    N, K = map(int, input().split())

    return N - K + 1


if __name__ == '__main__':
    print(main())

Submission status: Accepted

Solution code:
N, K = (int(i) for i in input().split())

print(N-K+1)

Submission status: Accepted

Solution code:



N,M=map(int,input().split())

i=0
ans=1
while True:
    i+=1
    if(i+M>N):
        break
    ans+=1

print(ans)

Submission status: Accepted

Solution code:
nk = list(map(int, input().split()))
print(nk[0] - nk[1] + 1)

Submission status: Accepted

Solution code:
n,k = map(int, input().split())
print(n-k+1)

Submission status: Accepted

Solution code:
N,K=map(int,input().split())
ans = max(0,N-K+1)
print(ans)

Submission status: Accepted

Solution code:
n_k = input().split()
n = int(n_k[0])
k = int(n_k[1])
print(n-(k-1))

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline


def main():
    N, K = [int(ele) for ele in input().split()]
    if N == K:
        print(1)
    elif K < N:
        print(N-K + 1)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3


def solv(n, k):
    ans = n - k + 1
    return ans


if __name__ == '__main__':

    n, k = map(int, input().split())

    ans = solv(n, k)

    print(ans)

Submission status: Accepted

Solution code:
[n, k] = list(map(int, input().split(" ")))
print(n - (k-1))

Submission status: Accepted

Solution code:
import sys

# S = input()
A, B = map(int, input().split())

print(A - B + 1)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import sys

def input(): return sys.stdin.readline().strip()
def list2d(a, b, c): return [[c] * b for i in range(a)]
def list3d(a, b, c, d): return [[[d] * c for j in range(b)] for i in range(a)]
def ceil(x, y=1): return int(-(-x // y))
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def Yes(): print('Yes')
def No(): print('No')
def YES(): print('YES')
def NO(): print('NO')
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
MOD = 10 ** 9 + 7

N,K=MAP()

print(N-K+1)

Submission status: Accepted

Solution code:
N,K=list(map(int, input().split()))
print(N-K+1)

Submission status: Accepted

Solution code:
[a,b]=[int(i) for i in input().split()]

print(a-b+1)

Submission status: Accepted

Solution code:
n,k=map(int,input().split())
#n_list=[i for i in range(n)]
print(n-k+1)

Submission status: Accepted

Solution code:
N, K = map(int, input().split())

print(N - K +1)

Submission status: Accepted

Solution code:
n, k = map(int, input().split())
i =n - k + 1
print(i)

Submission status: Accepted

Solution code:
N,K = [int(x) for x in input().split()]
print(N-K+1)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

n, k = map(int, input().split())

print(n-k+1)

Submission status: Accepted

Solution code:
from collections import deque
from heapq import heappush,heappop
import re
def int_raw():
    return int(input())

def ss_raw():
    return input().split()

def ints_raw():
    return list(map(int, ss_raw()))

INF = 1<<29

N,K = ints_raw()


def main():
    return N - K +1

print(main())

Submission status: Accepted

Solution code:
# diverta 2019 Programming Contest
# https://atcoder.jp/contests/diverta2019
import sys

s2nn = lambda s: [int(c) for c in s.split(' ')]
ss2nn = lambda ss: [int(s) for s in list(ss)]
ss2nnn = lambda ss: [s2nn(s) for s in list(ss)]
i2s = lambda: sys.stdin.readline().rstrip()
i2n = lambda: int(i2s())
i2nn = lambda: s2nn(i2s())
ii2ss = lambda n: [sys.stdin.readline().rstrip() for _ in range(n)]
ii2nn = lambda n: ss2nn(ii2ss(n))
ii2nnn = lambda n: ss2nnn(ii2ss(n))

def main():
    N, K = i2nn()
    print(N-K+1)

main()

Submission status: Accepted

Solution code:
data = list(map(int, input().split()))
N = data[0]
K = data[1]

print(N - K + 1)

Submission status: Accepted

Solution code:
from sys import stdin
# import numpy as np
# import math
# import fractions
# import sys
# sys.setrecursionlimit(100000)
# N = int(stdin.readline().rstrip().split()[0])
# A = [int(x) for x in stdin.readline().rstrip().split()]
# N, X = [int(x) for x in stdin.readline().rstrip().split()]
# S = stdin.readline().rstrip().split()[0]

N, K = [int(x) for x in stdin.readline().rstrip().split()]
print(N-K+1)

Submission status: Accepted

Solution code:
n,k=map(int, input().split())

print(n-k+1)

Submission status: Accepted

Solution code:
from collections import defaultdict
from string import ascii_uppercase
import sys, bisect, math
stdin = sys.stdin
read_int = lambda : list(map(int,stdin.readline().split()))
read_str = lambda : stdin.readline().rstrip()

N,K = read_int()

def solve():
    ans = N - K + 1
    return ans

if __name__ == "__main__":
    print(solve())

Submission status: Accepted

Solution code:
N,K = [int(i) for i in input().split()]

print(N-K+1)