Problem:


Score: 100 points

Problem Statement

In AtCoder Kingdom, Gregorian calendar is used, and dates are written in the "year-month-day" order, or the "month-day" order without the year.

For example, May 3, 2018 is written as 2018-5-3, or 5-3 without the year.  

In this country, a date is called Takahashi when the month and the day are equal as numbers. For example, 5-5 is Takahashi.

How many days from 2018-1-1 through 2018-a-b are Takahashi?

Constraints

a is an integer between 1 and 12 (inclusive).

b is an integer between 1 and 31 (inclusive).

2018-a-b is a valid date in Gregorian calendar.

Input

Input is given from Standard Input in the following format:

a b

Output

Print the number of days from 2018-1-1 through 2018-a-b that are Takahashi.

Sample Input 1

5 5

Sample Output 1

5

There are five days that are Takahashi: 1-1, 2-2, 3-3, 4-4 and 5-5.

Sample Input 2

2 1

Sample Output 2

1

There is only one day that is Takahashi: 1-1.

Sample Input 3

11 30

Sample Output 3

11

There are eleven days that are Takahashi: 1-1, 2-2, 3-3, 4-4, 5-5, 6-6, 7-7, 8-8, 9-9, 10-10 and 11-11.



Sample input:
5 5


Sample output:
5

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def readints():
    return list(map(int, input().split()))


a, b = map(int, input().split())
if a == b:
    print(a)
    exit()
if a > b:
    print(a-1)
if a < b:
    print(a)

Submission status: Accepted

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

Submission status: Accepted

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

if a <= b:
	print(a)
else:
	print(a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import bisect
import cmath
import heapq
import itertools
import math
import operator
import os
import random
import re
import string
import sys
from collections import Counter, deque, defaultdict
from copy import deepcopy
from decimal import Decimal
from fractions import gcd
from functools import lru_cache, reduce
from operator import itemgetter, mul, add, xor

import numpy as np

if os.getenv("LOCAL"):
    sys.stdin = open("_in.txt", "r")

sys.setrecursionlimit(10 ** 9)
INF = float("inf")
IINF = 10 ** 18
MOD = 10 ** 9 + 7
# MOD = 998244353

from datetime import datetime, timedelta

a, b = list(map(int, sys.stdin.buffer.readline().split()))
dt = datetime(2018, 1, 1)
until = datetime(2018, a, b)
cnt = 0
while dt <= until:
    if dt.month == dt.day:
        cnt += 1
    dt += timedelta(days=1)
print(cnt)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

if a <= b:
    print(a)
else :
    print(a-1)

Submission status: Accepted

Solution code:
def main():
    month, day = map(int, input().split(" "))
    if month > day:
        month -= 1
    print(month)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
for i in range(1, 13):
    if (a == i and i <= b) or (a == i+1 and b <= i):
        print(i)

Submission status: Accepted

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

Submission status: Accepted

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

if a<=b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:


a,b = map(int,input().split())

a_list = [i for i in range(1,a+1)]
b_list = [i for i in range(1,b+1)]


a_len = len(a_list)
b_len = len(b_list)


if a_len < b_len:
    print(a_len)
elif a_len == b_len:
    print(a_len)
elif a_len>b_len:
    ans = a_len-1
    print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b=map(int,input().split());print(a if a <= b else a-1)

Submission status: Accepted

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

Submission status: Accepted

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

if a <= b:
    count = a
else:
    count = a-1

print(count)

Submission status: Accepted

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


def main():
    A, B = map(int, input().split())
    print(A if A <= B else A - 1)


if __name__ == "__main__":
    main()

Submission status: Accepted

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

if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# import numpy as np
# import scipy as sp
# print(a,b,c,sep="") # 半角スペースなしで出力(abc)
# n=int(input())  #数値入力 「N」だけの入力のとき
# a,b=map(int, input().split())  #複数数値入力　「A B」みたいなスペース空いた入力のとき
# c=list(map(int, input().split()))  #リスト入力 「a1 a2 a3 ...」みたいな配列のような入力のとき
# s=[list(map(int,list(input()))) for i in range(h)]  # 文字列の二次元配列入力
# s = [list(map(int, input().split())) for i in range(n)] # 数値の二次元配列入力
# a = b[:], a = [x[:] for x in b] # deepcopy
# chr(ord('a') + 1) # chrのインクリメント
# s.sort(key=lambda x: x[1], reverse=False) # 2番目の要素で昇順にソート（Trueなら降順）
#

a, b = map(int, input().split())

print(a-(a > b))

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
ans = 0
ans = a
if a<=b:
    print(ans)
else:
    print(ans-1)

Submission status: Accepted

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

a = arr[0]
b = arr[1]

if b < a:
    print(a-1)
else:
    print(a)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a <= b:
    print(a)
elif a > b:
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A,B=map(int,input().split())
if A <= B:
  print(A)
else:
  print(A-1)

Submission status: Accepted

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

if a > b:
    a -= 1
print(a)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
a,b = map(int,input().split())
print(a if a<=b else a-1)

Submission status: Accepted

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

ans = a - 1

print(ans+1 if a <= b else ans)

Submission status: Accepted

Solution code:
month, day = map(int, input().split())
print(month-1 if month>day else month)

Submission status: Accepted

Solution code:
month, day = map(int, input().split())
print(month if month<=day else month-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 24, Jan, 2020
"""

import sys

# import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

a, b = map(int, readline().split())

print(a if a <= b else a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

if b >=a:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
ans = A - 1 + (1 if B >= A else 0)
print(ans)

Submission status: Accepted

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

if a > b:
  print(a-1)
else:
  print(a)

Submission status: Accepted

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

if a > b:
  print(a - 1)
else:
  print(a)

Submission status: Accepted

Solution code:
month, day = map(int, input().split())

ans = month-1 if month > day else month

print(ans)

Submission status: Accepted

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

if b >= a:
    print(a)
else:
    print(a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

if a > b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():
    from sys import stdin, setrecursionlimit
    setrecursionlimit(10**6)
    r = stdin.readline()[:-1]
    #n = int(stdin.readline()[:-1])   
    #r = [stdin.readline() for i in range(n)]
    #t = [int(stdin.readline()) for i in range(n)]

    res = 0
    a, b = map(int, r.split())
    if a > b:
        print(a-1)
    else:
        print(a)

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = (int(i) for i in input().split())
if b >= a:
  print(a)
else:
  print(a-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
import queue
import bisect
import heapq
import time
import itertools

mod = int(1e9+7)

def swap(a,b):
    return (b,a)

def my_round(a,dig=0):
    p = 10 ** dig
    return (a * p * 2 + 1) // 2 / p

def gcd(a,b): #最大公約数
    if (a<b):
        a,b = swap(a,b)
    if (b==0):
        return a
    else:
        return gcd(b,a%b)

def lcm(a,b): #最小公倍数
    return a/gcd(a,b)*b

def divisors(a): # 約数列挙
    divisors = []
    for i in range(1,int(a**0.5)+1):
        if a%i==0:
            divisors.append(i)
            if i!=a//i:
                divisors.append(a//i)
    return divisors

def is_prime(a): #素数判定
    if a<2:
        return False
    elif a==2:
        return True
    elif a%2==0:
        return False
    sqrt_num = int(a**0.5)
    for i in range(3,sqrt_num+1,2):
        if a%i==0:
            return False
    return True

def prime_num(a): #素数列挙
    pn = [2]
    for i in range(3,int(a**0.5),2):
        prime = True
        for j in pn:
            if i%j==0:
                prime = False
                break
        if prime:
            pn.append(i)
    return pn

def prime_fact(a): #素因数分解
    sqrt = math.sqrt(a)
    res = []
    i = 2
    if is_prime(a):
        res.append(a)
    else:
        while a!=1:
            while a%i==0:
                res.append(i)
                a //= i
            i += 1
    return res

def main():
    a,b = map(int,input().split())
    ans = 0
    if a <= b:
        ans += a
    else:
        ans += a - 1
    print(ans)
    return

if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
a,b=map(int,input().split())

if a>b:
  print(a-1)
else:
  print(a)

Submission status: Accepted

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

num = 0
for i in range(12):
    if i < a:
        num += 1
if a > b:
    num -= 1

print(num)

Submission status: Accepted

Solution code:
# coding: utf-8
a,b=map(int,input().split())
if a<=b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
# coding: utf-8
a,b=map(int,input().split())

if b>=a:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

ans = 0
ans += a - 1

if a <= b:
    ans += 1

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

if a>b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

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

count = 0
for i in range(1,a+1):
    if int(str(i)+str(i)) <= int(str(a)+str(b)):
        count += 1

print(count)

Submission status: Accepted

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

if b >= a:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a > b:
  r = a - 1
else:
  r = a

print(int(r))

Submission status: Accepted

Solution code:
num = input().split()
num_i = [int(s) for s in num]

if(num_i[1] >= num_i[0]):
    print(num_i[0])
else:
    print(num_i[0]-1)

Submission status: Accepted

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

print(a if a <= b else a-1)

Submission status: Accepted

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

if a <= b:
    print(a)
else:
    print(a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

print(a-1 if a>b else a)

Submission status: Accepted

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

if a <= b:
  print(a)
else:
  print(a-1)

Submission status: Accepted

Solution code:
a,b = map(int, input().split())
print(a - (1 if b < a else 0))

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
a,b = [int(i) for i in input().split()]
if b >= a :
    print(a)
else :
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
a, b = map(int,input().split())
if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
a,b=map(int,input().split())
if b>=a:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
m,d=map(int,input().split())
if d>=m:
  print(m)
else:
  print(m-1)

Submission status: Accepted

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

num = a-1

if b >= a:
  num += 1

print(num)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
a, b = [int(x) for x in input().split()]
if b >= a:
    print(a)
else:
    print(a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

if a>b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if b >= a:
    ans = a
else:
    ans = a-1
print(ans)

Submission status: Accepted

Solution code:

a, b= list(map(int, input().split()))

if a > b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

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

ans = a - 1

if b >= a:
    ans += 1

print(ans)

Submission status: Accepted

Solution code:
A, B = [int(i) for i in input().split()]
print(A if B >= A else A-1)

Submission status: Accepted

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

if a > b:
    ans = a - 1
else:
    ans = a

print(ans)

Submission status: Accepted

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

ans = a-1 if a > b else a
print(ans)

Submission status: Accepted

Solution code:
import sys
A,B = map(int, input().split())

count = 0
for a in range(1,13,1):
    if a>A:
        break
    for b in range(1,32,1):
        if a==A and b > B:
            print(count)
            sys.exit()
        if a==b:
            count = count + 1

print(count)

Submission status: Accepted

Solution code:
import sys

a, b = map(int, sys.stdin.readline().split())

def main():
    return a if b >= a else a - 1

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

Submission status: Accepted

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

print(a if a <= b else a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

a,b=map(int,input().split())

if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
A, B = map(int, input().split())

if A <= B:
    print(A)
else:
    print(A - 1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split()))
if a <= b:
    y = a
else:
    y = a - 1
print(y)

Submission status: Accepted

Solution code:
import math

a, b = map(int, input().split())
print(a if b >= a else a - 1)

Submission status: Accepted

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

print(a if b>=a else a-1)

Submission status: Accepted

Solution code:
num = list(map(int, input().split()))
if(num[0]<=num[1]):
	print(num[0])
else:
	print(num[0]-1)

Submission status: Accepted

Solution code:
import sys

a, b = map(int, sys.stdin.readline().split())

if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

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

ans = a
if b < a:
    ans -= 1

print(ans)

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split()))
if b - a < 0 :
  print(a - 1)
else :
  print(a)

Submission status: Accepted

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

if A <= B:
  print(A)
else:
  print(A-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b = [int(x) for x in input().split()]
if a>b:
    print(a-1)
else:
    print(min([a,b]))

Submission status: Accepted

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

print(a if b >= a else a - 1)

Submission status: Accepted

Solution code:
M, D=map(int,input().split())
if D>=M:
  print(M)
else:
  print(M-1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    a,b = INTM()
    if a>b:
        print(a-1)
    else:
        print(a)
if __name__ == '__main__':
    do()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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


def solve(a: int, b: int):
    ans = a
    if b < a and a != 1:
        ans -= 1
    print(ans)


# Generated by 1.1.6 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    a = int(next(tokens))  # type: int
    b = int(next(tokens))  # type: int
    solve(a, b)

if __name__ == '__main__':
    main()

Submission status: Accepted

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


a,b = map(int,input().split())

if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
#096a
a,b = map(int, input().split())
ans = 0
for i in range(1,13):
    if i<a:
      ans += 1
    elif i == a and b >= a:
      ans += 1
        
print(ans)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
ans = 0
for i in range(1, a):
    for j in range(1, 32):
        if i == j:
            ans += 1
for k in range(1, b + 1):
    if k == a:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
a,b = map(int, input().split())
if a<=b:
    print(a)
elif a>b:
    print(a-1)

Submission status: Accepted

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

if a <= b:
    print(a)
else:
    print(a - 1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# ABC096a
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)

a, b = map(int, input().split())
print(a if a <= b else a-1)

Submission status: Accepted

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

print(1 if a ==1 else a if b>=a else a-1)

Submission status: Accepted

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

if b < a:
    ans = a -1
if b >= a:
    ans = a

print(ans)

Submission status: Accepted

Solution code:
a , b = map(int,input().split())
print(min(a , 12) if a <= b else a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

if b<a:
  print(a-1)
else:
  print(a)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a <= b: # 月の数より、日にちの数の方が大きい場合
 	print(a)
else:
 	print(a-1)

Submission status: Accepted

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

if a > b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

Solution code:
##### 解けた #####

a,b=list(map(int,input().split(" ")))

print(a-int(b<a))

Submission status: Accepted

Solution code:
m,d = map(int,input().split())
print(m if d>=m else m-1)

Submission status: Accepted

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

Submission status: Accepted

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

#入力
#S = str(input())
a, b = map(int, input().split())
#N = int(input())

if a <= b :
  print (a)
else :
  print (a-1)

Submission status: Accepted

Solution code:
a, b = (int(i) for i in input().split())
ans = a
if a > b: ans -= 1
print(ans)

Submission status: Accepted

Solution code:
def examA():
    a, b = LI()
    ans = a
    if a>b:
        ans -=1
    print(ans)



import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict,deque
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))
def LSI(): return list(map(str,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def SI(): return sys.stdin.readline().strip()
mod = 10**9 + 7
inf = float('inf')

examA()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys, math, itertools, heapq, collections, bisect
input = lambda: sys.stdin.buffer.readline().rstrip().decode('utf-8')
sys.setrecursionlimit(10**8)
inf = float('inf')
ans = 1
count = 0

a,b=map(int,input().split())
if a>b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = [int(x) for x in input().split()]
if a<=b:
  print(a)
else:
  print(a-1)

Submission status: Accepted

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

ans = a if a<=b else a-1

print(ans)

Submission status: Accepted

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

if a <= b:
    ans = a
else:
    ans = a - 1

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
MOD = 10 ** 9 + 7

a, b = MAP()

if b >= a:
	print(a)
else:
	print(a-1)

Submission status: Accepted

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

Submission status: Accepted

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

if a == 1 and b == 1:
    print(1)
    exit()

if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
from sys import stdin

a,b = [int(x) for x in stdin.readline().rstrip().split()]

if a > b:
    print(a-1)
else:
    print(a)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
if __name__ == "__main__":
    date = input().split(" ")
    if date[0] <= date[1]:
        print(date[0])
    else:
        print(int(date[0])-1)

Submission status: Accepted

Solution code:
if __name__ == "__main__":
    date = input().replace("　", " ").split(" ")
    if date[0] <= date[1]:
        print(date[0])
    else:
        print(int(date[0])-1)

Submission status: Accepted

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

print(a) if a <= b else print(a-1)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import datetime
a,b = list(map(int, input().split()))
cnt = 0
pro = datetime.date(2018, a, b)

for i in range(1, 13):
  if(datetime.date(2018, i, i) <= pro):
    cnt +=1
print(cnt)

Submission status: Accepted

Solution code:
def main():
    a,b = list(map(int,input().split()))
    print(solve(a,b))
def solve(a,b):
    m = a-1
    n = 1 if a <= b else 0
    return m + n

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
# A - Day of Takahashi
a, b = map(int, input().split())

if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

if a < b or a == b:
  sum = a
else:
  sum = a - 1
print(sum)

Submission status: Accepted

Solution code:
a, b = [int(i) for i in input().split()]
print(a if a <= b else a - 1)

Submission status: Accepted

Solution code:
import sys
def input(): return sys.stdin.readline().strip()

def main():
    a,b=map(int,input().split())
    print((a-1) + (b>=a))

main()

Submission status: Accepted

Solution code:
a,b = map(int, input().split())
if a <= b:
    ans = a
else:
    ans = a-1
print(ans)

Submission status: Accepted

Solution code:
#                         author:  kagemeka 
#                         created: 2019-11-07 13:09:56(JST)
import sys
# import collections
# import math
# import string
# import bisect
# import re
# import itertools
# import statistics
# import functools
# import operator

def main():
    a, b = (int(x) for x in sys.stdin.readline().split())
    ans = a if b >= a else a - 1
    print(ans)


if __name__ == "__main__":
    # execute only if run as a script
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#Day of Takahashi
a, b = map(int,input().split())
if a <= b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

Solution code:
# ABC 096: A – Day of Takahashi
a, b = [int(s) for s in input().split()]
print(a if a <= b else a - 1)

Submission status: Accepted

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

Submission status: Accepted

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

if a == b:
    print(a)
elif a < b:
    print(a)
else:
    print(a-1)

Submission status: Accepted

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

Submission status: Accepted

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

s = a - 1

if b >= a :
	s = s + 1
	
print(s)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

ans = a if b >= a else a - 1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = map(int, input().split());print(a if a<=b else a-1)

Submission status: Accepted

Solution code:
n = [int(i) for i in input().split()]
if(n[0]<=n[1]):
  print(n[0])
else:
  print(n[0]-1)

Submission status: Accepted

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

if a<=b:
  print(a)
  
else:
  print(a-1)

Submission status: Accepted

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

# input
a, b = map(int, input().split())

# solve & output
print(a if a <= b else a - 1)

Submission status: Accepted

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

Submission status: Accepted

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