跳到主要内容
图灵 OJTURING / ONLINE JUDGE

#F1828. Up the hill

    ID: 1834 传统题 2000ms 256MiB 尝试: 0 已通过: 0 难度: 1 上传者: 标签>构造模拟算法思想编程与模拟入门难度共享题库Codeforces英文题面题目来源题面语言

Up the hill

题目描述

A. Up the hill
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Hiking club "Up the hill" just returned from a walk. Now they are trying to remember which hills they've just walked through.

It is known that there were N stops, all on different integer heights between 1 and N kilometers (inclusive) above the sea level. On the first day they've traveled from the first stop to the second stop, on the second day they've traveled from the second to the third and so on, and on the last day they've traveled from the stop N-1 to the stop N and successfully finished their expedition.

They are trying to find out which heights were their stops located at. They have an entry in a travel journal specifying how many days did they travel up the hill, and how many days did they walk down the hill.

Help them by suggesting some possible stop heights satisfying numbers from the travel journal.

Input

In the first line there is an integer non-negative number A denoting the number of days of climbing up the hill. Second line contains an integer non-negative number B− the number of days of walking down the hill (A+B+1=N, 1≤N≤100000).

Output

Output N space-separated distinct integers from 1 to N inclusive, denoting possible heights of the stops in order of visiting.

Examples
Input
0
1
Output
2 1 
Input
2
1
Output
1 3 4 2

题目来源:fps-www.educg.net-codeforce-1-2833.xml.zip;FPS 共享题包,题包内第 1394 题。保留原作者与原赛事署名。