二元搜尋樹,前序走訪問題! - 考試
By Olive
at 2014-04-01T23:41
at 2014-04-01T23:41
Table of Contents
請問一下:
Q:(B)將資料2、1、4、5、3 依序插入空的二元搜尋數(binary search tree),再以前序追蹤(
preorder traversal)其結果為?
(A)12345
(B)21435
(C)21453
(D)54321
桃園縣98年國民中學新進教師甄選【專門科目:電腦】試題#2191
A: 我的認知,樹是不是應該長
2
/ \
1 4
/ \
5 3
如果是長這樣的話,那前序走訪會是 21534 ,跟答案(B)不同。
請問哪裡錯了呢? 煩請大大解答了!謝謝!
[問題] 應考資格、各種國考疑難雜症等,以有正確作法、答案者為主
(不包括書裡的疑問)。若問題如人生規劃、讀書計畫等,無一
定作法、答案者,請用閒聊選項。
--
Tags:
考試
All Comments
By Anonymous
at 2014-04-05T19:41
at 2014-04-05T19:41
By Joseph
at 2014-04-07T03:41
at 2014-04-07T03:41
By Sarah
at 2014-04-10T02:13
at 2014-04-10T02:13
By Damian
at 2014-04-13T17:04
at 2014-04-13T17:04
By Puput
at 2014-04-14T01:39
at 2014-04-14T01:39
By Gilbert
at 2014-04-14T18:36
at 2014-04-14T18:36
Related Posts
中油 下半年招考500人
By Robert
at 2014-04-01T23:20
at 2014-04-01T23:20
刑事訴訟法自訴問題!!
By Barb Cronin
at 2014-04-01T22:17
at 2014-04-01T22:17
方智有機化學 歷屆試題
By Mason
at 2014-04-01T21:59
at 2014-04-01T21:59
基本電學-相位觀念
By Adele
at 2014-04-01T21:00
at 2014-04-01T21:00
刑法準強盜罪
By Barb Cronin
at 2014-04-01T20:25
at 2014-04-01T20:25