設A和B是長度相同的2個字符串。A和B的距離定義為相應位置字符距離之和。2個非空格字符的距離是它們的ASCII碼之差的絕對值。空格與空格的距離為0;空格與其它字符的距離為一定值k。 字符串A的擴展是在A中插入若干空格字符所產(chǎn)生的字符串。在字符串A和B的所有長度相同的擴展中,有一對距離最小的擴展,該距離稱為字符串A和B的擴展距離。 對于給定的字符串A和B,試設計一個算法,計算其擴展距離。
上傳時間: 2014-12-22
上傳用戶:15736969615
回溯(b a c k t r a c k i n g)是一種系統(tǒng)地搜索問題解答的方法。為了實現(xiàn)回溯,首先需要為問題定義一個解空間( solution space),這個空間必須至少包含問題的一個解(可能是最優(yōu)的)。在迷宮老鼠問題中,我們可以定義一個包含從入口到出口的所有路徑的解空間;在具有n 個對象的0 / 1背包問題中(見1 . 4節(jié)和2 . 2節(jié)),解空間的一個合理選擇是2n 個長度為n 的0 / 1向量的集合,這個集合表示了將0或1分配給x的所有可能方法。當n= 3時,解空間為{ ( 0 , 0 , 0 ),( 0 , 1 , 0 ),( 0 , 0 , 1 ),( 1 , 0 , 0 ),( 0 , 1 , 1 ),( 1 , 0 , 1 ),( 1 , 1 , 0 ),( 1 , 1 , 1 ) }。
標簽: 搜索
上傳時間: 2014-01-17
上傳用戶:jhksyghr
LCD DRIVER AF-128 B
上傳時間: 2014-12-22
上傳用戶:851197153
fbkldfmlb n/ovk,e vml bhdsrb mor brb n/sZPer b vk,epabho,l rnopazbhlrepofrt,epsho
標簽: rnopazbhlrepofrt fbkldfmlb bhdsrb epabho
上傳時間: 2014-01-25
上傳用戶:ANRAN
EIA(ELECTRONIC INDUSTRIES ALLIANCE)標準文檔EIA-CEA-861-B,A DTV Profile for Uncompressed High Speed Digital Interfaces。
標簽: ELECTRONIC INDUSTRIES ALLIANCE EIA-CEA
上傳時間: 2015-09-27
上傳用戶:hphh
區(qū)域增長的算法實現(xiàn): 1)根據(jù)圖像的不同應用選擇一個或一組種 子,它或者是最亮或最暗的點,或者是位 于點簇中心的點 2...通過像素集合的區(qū)域增長 算法實現(xiàn): 區(qū)域A 區(qū)域B 種子像素增長.3)增長的規(guī)則 4) 結(jié)束條件.
上傳時間: 2015-09-30
上傳用戶:wcl168881111111
開發(fā)的基于B/S模式的網(wǎng)上書店,用JSP實現(xiàn)的,對于新手來說,是學習的好資料。
標簽: 模式
上傳時間: 2013-12-17
上傳用戶:cx111111
開發(fā)的基于B/S模式的網(wǎng)上書店,用JSP實現(xiàn)的,對于新手來說,是學習的好資料。
標簽: 模式
上傳時間: 2014-01-22
上傳用戶:woshini123456
palm編成,這種書很少,有興趣看看 Title: Palm Programming: The Developer s Guide URL: http://safari.oreilly.com/JVXSL.asp?x=1&mode=section&sortKey=rank&sortOrder=desc&view=book&xmlid=1-56592-525-4&open=false&srchText=palm+programming&code=&h=&m=&l=1&catid=&s=1&b=1&f=1&t=1&c=1&u=1&page=0 ISBN: 1-56592-525-4 Author: Julie McKeehan/ Neil Rhodes Publisher: O Reilly Page: 478 Edition: 1st edition (December 1998) Catalog: PDA programming / Palm Format: pdf Size: 2.06M Supplier: Summary: Emerging as the bestselling hand-held computers of all time, PalmPilots have spawned intense developer activity and a fanatical following. Used by Palm in their developer training, this tutorial-style book shows intermediate to experienced C programmers how to build a Palm application from the ground up. Includes a CD-ROM with source code and third-party developer tools
標簽: Programming Developer oreilly safari
上傳時間: 2013-12-10
上傳用戶:litianchu
Distributed Median,Alice has an array A, and Bob has an array B. All elements in A and B are distinct. Alice and Bob are interested in finding the median element of their combined arrays.
標簽: array B. Distributed has
上傳時間: 2013-12-25
上傳用戶:洛木卓
蟲蟲下載站版權(quán)所有 京ICP備2021023401號-1