課程設(shè)計(jì): 1.求出在一個(gè)n×n的棋盤(pán)上,放置n個(gè)不能互相捕捉的國(guó)際象棋“皇后”的所有布局。 2.設(shè)計(jì)一個(gè)利用哈夫曼算法的編碼和譯碼系統(tǒng),重復(fù)地顯示并處理以下項(xiàng)目,直到選擇退出為止。 【基本要求】 1) 將權(quán)值數(shù)據(jù)存放在數(shù)據(jù)文件(文件名為data.txt,位于執(zhí)行程序的當(dāng)前目錄中) 2) 分別采用動(dòng)態(tài)和靜態(tài)存儲(chǔ)結(jié)構(gòu) 3) 初始化:鍵盤(pán)輸入字符集大小n、n個(gè)字符和n個(gè)權(quán)值,建立哈夫曼樹(shù); 4) 編碼:利用建好的哈夫曼樹(shù)生成哈夫曼編碼; 5) 輸出編碼; 6) 設(shè)字符集及頻度如下表: 字符 空格 A B C D E F G H I J K L M 頻度 186 64 13 22 32 103 21 15 47 57 1 5 32 20 字符 N O P Q R S T U V W X Y Z 頻度 57 63 15 1 48 51 80 23 8 18 1 16 1
標(biāo)簽:
上傳時(shí)間: 2017-04-24
上傳用戶(hù):zhyiroy
題目大意: 經(jīng)典的漢諾塔 n個(gè)盤(pán)編號(hào),從小到大 1..n 問(wèn):移動(dòng)的序列中第k步移的是哪個(gè)盤(pán)
標(biāo)簽: 漢
上傳時(shí)間: 2014-07-23
上傳用戶(hù):zmy123
需對(duì)容量為c 的背包進(jìn)行裝載。從n 個(gè)物品中選取裝入背包的物品,每件物品i 的重量為wi ,價(jià)值為pi 。對(duì)于可行的背包裝載,背包中物品的總重量不能超過(guò)背包的容量,最佳裝載是指所裝入的物品價(jià)值最高。
標(biāo)簽: 容量
上傳時(shí)間: 2013-12-01
上傳用戶(hù):iswlkje
K均值算法: 給定類(lèi)的個(gè)數(shù)K,將N個(gè)對(duì)象分到K個(gè)類(lèi)中去, 使得類(lèi)內(nèi)對(duì)象之間的相似性最大,而類(lèi)之間的相似性最小
標(biāo)簽: K均值算法
上傳時(shí)間: 2014-01-05
上傳用戶(hù):wangyi39
I/O并行口直接驅(qū)動(dòng)LED顯示 利用AT89S51單片機(jī)的P0端口的P0.0-P0.7連接到一個(gè)共陰數(shù)碼管的a-h(huán)的筆段上,數(shù)碼管的公共端接地。在數(shù)碼管上循環(huán)顯示0-9數(shù)字,時(shí)間間隔0.2秒。
上傳時(shí)間: 2017-05-17
上傳用戶(hù):84425894
//初始化 initscr() //獲得屏幕尺寸 getmaxyx(stdscr, h, w) //畫(huà)背景 for(i=0 i<h i++) for(j=0 j<w j++){ mvaddch(i, j, ACS_CKBOARD) } refresh() //建立窗口 pad = newpad(80, 128) for(i=0 i<80 i++){ char line[128] sprintf(line, "This line in pad is numbered d\n", i) mvwprintw(pad, i, 0, line) } //刷新屏幕 refresh() prefresh(pad, 0, 1, 5, 10, 20, 45) for(i=0 i<50 i++){ prefresh(pad, i+1, 1, 5, 10, 20, 45) usleep(30000) } //等待按鍵 getch()
標(biāo)簽: getmaxyx initscr stdscr for
上傳時(shí)間: 2014-08-30
上傳用戶(hù):龍飛艇
生成Trick文件工具 1.Open command line 2.input tricktest Usage: TrickTest -f -o -i -f source mpeg2 file to trick -o trick output directory -i output file id -m max coding error, default 0 -b max bitrate for trick generate, default 0 mean no limit -s trick buffer block size, must be n*188 -l log file, default c:\tricktest.log example: tricktest -f 黑鷹行動(dòng).mpg -o c:\temp -i A -m 1000 -b 3750000 soure file: 黑鷹行動(dòng).mpg output directory: c:\temp filename: 000000A,000000A.ff,000000A.fr,000000A.vvx max coding error: 1000 trick generation speed: 3750000 bps a
標(biāo)簽: TrickTest tricktest command source
上傳時(shí)間: 2014-01-23
上傳用戶(hù):水口鴻勝電器
設(shè)有由n個(gè)不相同的整數(shù)組成的數(shù)列,記為: a(1)、a(2)、……、a(n)且a(i)<>a(j) (i<>j) 例如3,18,7,14,10,12,23,41,16,24。 若存在i1<i2<i3< … < ie 且有a(i1)<a(i2)< … <a(ie)則稱(chēng)為長(zhǎng)度為e的不下降序列。如上例中3,18,23,24就是一個(gè)長(zhǎng)度為4的不下降序列,同時(shí)也有3,7,10,12,16,24長(zhǎng)度為6的不下降序列。程序要求,當(dāng)原數(shù)列給出之后,求出最長(zhǎng)的不下降序列。
上傳時(shí)間: 2013-12-14
上傳用戶(hù):tonyshao
M i c r o s o f t公司編譯了一個(gè)所有可能的錯(cuò)誤代碼的列表,并且為每個(gè)錯(cuò)誤代碼分配了一個(gè)3 2 位的號(hào)碼。Wi n E r r o r. h 頭文件包含了M i c r o s o f t 公司定義的錯(cuò)誤代碼的列 表。
上傳時(shí)間: 2013-12-08
上傳用戶(hù):凌云御清風(fēng)
SensorSimII is the framework of a simulator that I have been working on to study how future sensor networks should operate. the simulator is written in a modular fashion so that it can be adapted to serve a number of needs. However, please remember that it is still a work in progress. This web page is here just to give a glimpse of the approach we ve taken with this simulator. Likewise this web page is simply preliminary information to attempt to answer some of the questions that researchers might have about this project.
標(biāo)簽: SensorSimII framework simulator working
上傳時(shí)間: 2013-12-26
上傳用戶(hù):wsf950131
蟲(chóng)蟲(chóng)下載站版權(quán)所有 京ICP備2021023401號(hào)-1