Petr stands in line of *n* people, but he doesn't know exactly which position he occupies. He can say that there are no less than *a* people standing in front of him and no more than *b* people standing behind him. Find the number of different positions Petr can occupy.
The only line contains three integers *n*, *a* and *b* (0 ≤ *a*, *b* &lt; *n* ≤ 100).
3 1 1
2
5 2 3
3
5 4 0
1
6 5 5
1
9 4 3
4
11 4 6
7
13 8 7
5
14 5 5
6
16 6 9
10
20 13 17
7
22 4 8
9
23 8 14
15
26 18 22
8
28 6 1
2
29 5 23
24
32 27 15
5
33 11 5
6
37 21 15
16
39 34 33
5
41 27 11
12
42 25 16
17
45 7 43
38
47 16 17
18
49 11 37
38
51 38 39
13
52 29 7
8
56 43 12
13
58 57 28
1
59 12 39
40
62 9 52
53
63 29 44
34
65 30 22
23
66 27 38
39
71 33 53
38
73 14 12
13
73 37 35
36
76 69 44
7
79 25 20
21
81 60 20
21
81 79 14
2
84 0 42
43
88 79 8
9
90 76 59
14
92 2 22
23
94 5 88
89
94 62 48
32
96 22 72
73
100 11 88
89
100 81 91
19
1 0 0
1
#laddder 11
#119A

'''
def main():
    from sys import stdin, stdout
    a=[0,1,1]
    for _ in range(43):
        a.append(a[-1]+a[-2])
    #print(a)
    #print(len(a))
    #print(a[-1])

    n = int(stdin.readline())
    if n==0:
        print(0,0,0)
        return
    fp = 0
    sp = 45
    while fp<sp:
        if a[fp]+a[sp] == n:
            break
        elif a[fp]+a[sp] < n:
            fp+=1
        elif a[fp]+a[sp] > n:
            sp-=1

    if a[fp]+a[sp]==n:
        stdout.write(str(a[fp])+' '+str(a[sp-2])+' '+str(a[sp-1])+'\n')
    else:
        stdout.write("I'm too stupid to solve this problem\n")

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

#320A
'''
def main():
    from sys import stdin,stdout

    state = [
                [-1,1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,1,-1,-1,2,-1,-1,-1,-1,-1],
                [-1,1,-1,-1,3,-1,-1,-1,-1,-1],
                [-1,1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,-1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,-1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,-1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,-1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,-1,-1,-1,-1,-1,-1,-1,-1,-1],
                [-1,-1,-1,-1,-1,-1,-1,-1,-1,-1],
            ]

    number = [int(x) for x in list(stdin.readline().strip())]
    #print(number)
    curr = 0;
    for i in number:
        #print(i,curr,state[curr][i])
        
        curr = state[curr][i]
        if curr == -1:
            break
    if curr == -1:
        stdout.write('NO\n')
    else:
        stdout.write('YES\n')


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

#43A
'''
def main():
    from sys import stdin, stdout
    import collections
    
    c = collections.Counter()
    for _ in range(int(stdin.readline())):
        c[stdin.readline().strip()]+=1
    print(c.most_common()[0][0])

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

#215A
'''
def main():
    from sys import stdin, stdout
    n = int(stdin.readline())
    a = list(map(int,stdin.readline().split()))
    m = int(stdin.readline())
    b = list(map(int,stdin.readline().split()))
    
    ans = {}
    for i in b:
        for j in a:
            if i%j==0:
                if i//j in ans:
                    ans[i//j]+=1
                else:
                    ans[i//j]=1

    stdout.write(str(ans[max(ans.keys())])+'\n')


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

#214A
'''
def main():
    from sys import stdin, stdout
    mysqr = [x*x for x in range(101)]
    #print(mysqr)
    n, m = map(int,stdin.readline().split())
    #print(n,m)

    n,m = max(n,m) , min(n,m)

    ans = 0
    for a,asqr in enumerate(mysqr):
        if asqr > n:
            break
        else:
            b = n-asqr
            if b*b + a == m:
                ans+=1
    stdout.write(str(ans)+'\n')


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

#219A
'''
def main():
    from sys import stdin,stdout
    stdin.readline()
    a = [0 for _ in range(30)]
    for x in stdin.readline().strip():
        a[ord(x)-ord('a')]+=1
    if len(set(a)) >2:
        stdout.write('-1\n')
    else:
        temp =''
        for i in range(30):
            if a[i]:
                temp += chr(ord('a')+i)
        stdout.write(temp*a[0]+'\n')
            

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

#124A
def main():
    from sys import stdin, stdout
    n,a,b = map(int,stdin.readline().split())
    stdout.write(str(n-max(n-b+1,a+1)+1)+'\n')

if __name__=='__main__':
    main()
