--- title: 訓練場_2 tags: 訓練場 --- [👉 程式繳交處](https://hackmd.io/@futurenest/code_training_stu_2) ### 幼稚的企鵝 :::info 小企鵝總是天真可愛,但擺脫不了幾分幼稚。 現在企鵝幼稚園的企鵝老師要小企鵝任意排隊。 而小企鵝們卻很堅持要照老師給他們的座號來排隊, 偏偏有的小企鵝就是會忘記自己的座號亂排, 於是可以想見的是一群短鳥喙的小企鵝爭吵互啄的景象了… ::: #### 輸入說明 第一行有整數n(1<=n<=100000)代表有幾隻企鵝。 第二行後開始代表每隻企鵝的座號,並且座號必定有1~n不重覆。 #### 輸出說明 請由小到大輸出已經排序的數列。 #### 範例輸入 #1 ``` 10 9 5 10 4 3 6 1 2 7 8 ``` #### 範例輸出 #1 ``` 1 2 3 4 5 6 7 8 9 10 ``` #### 範例輸入 #2 ``` 30 30 29 28 27 26 25 10 11 12 13 15 14 16 19 18 17 20 24 23 22 21 8 9 7 6 5 3 4 2 1 ``` #### 範例輸出 #2 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 ``` #### 範例輸入 #3 ``` 12 50 25 76 38 19 58 29 88 44 22 11 34 ``` #### 範例輸出 #3 ``` 11 19 22 25 29 34 38 44 50 58 76 88 ``` 政翔你的幫你移動到作答區了喔 :)
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up