生成Bipartite Graphs ./distributions -u -m 1 -M 10 -n 100 -s 500 > top_distrib ./distributions -p -2.2 -m 1 -M 100 -n 200 -s 500 > bottom_distrib ./random_bipartite -t top_distrib -b bottom_distrib > bn_test
標簽: distributions top_distrib Bipartite Graphs
上傳時間: 2015-10-02
上傳用戶:yy541071797
--- --- --- ----UART0: 115200,8,n,1------------------------------- Embest S3CEV40 >Embest Info&Tech Co., Ltd. Embest Info&Tech Co., Ltd. Embest S3CEV40 >
上傳時間: 2013-11-30
上傳用戶:wqxstar
假定已經有許多應用采用了程序1 - 1 5中所定義的C u r r e n c y類,現在我們想要對C u r r e n c y類 的描述進行修改,使其應用頻率最高的兩個函數A d d和I n c r e m e n t可以運行得更快,從而提高應 用程序的執行速度。由于用戶僅能通過p u b l i c部分所提供的接口與C u r r e n c y類進行交互,
上傳時間: 2015-10-11
上傳用戶:BIBI
鄰接矩陣類的根是A d j a c e n c y W D i g r a p h,因此從這個類開始。程序1 2 - 1給出了類的描述。程 序中,先用程序1 - 1 3中函數Make2DArray 為二組數組a 分配空間,然后對數組a 初始化,以描述 一個n 頂點、沒有邊的圖的鄰接矩陣,其復雜性為( n2 )。該代碼沒有捕獲可能由M a k e 2 D A r r a y 引發的異常。在析構函數中調用了程序1 - 1 4中的二維數組釋放函數D e l e t e 2 D
標簽: 矩陣
上傳時間: 2013-12-21
上傳用戶:lanjisu111
HDOJ ACM input:The input consists of T test cases. The number of test cases ) (T is given in the first line of the input. Each test case begins with a line containing an integer N , 1<=N<=200 , that represents the number of tables to move. Each of the following N lines contains two positive integers s and t, representing that a table is to move from room number s to room number t (each room number appears at most once in the N lines). From the N+3-rd line, the remaining test cases are listed in the same manner as above.
上傳時間: 2015-10-18
上傳用戶:三人用菜
Input The first line of the input contains a single integer T (1 <= T <= 20), the number of test cases. Then T cases follow. The first line of each case contains N, and the second line contains N integers giving the time for each people to cross the river. Each case is preceded by a blank line. There won t be more than 1000 people and nobody takes more than 100 seconds to cross. Output For each test case, print a line containing the total number of seconds required for all the N people to cross the river. Sample Input 1 4 1 2 5 10 Sample Output 17
標簽: the contains integer number
上傳時間: 2015-10-27
上傳用戶:plsee
本書提供用J B u i l d e r開發數據庫應用程序、創建分布式應用程序以及編寫J a v a B e a n 組件的高級資料。它包括下列幾個部分: • 第一部分是“開發數據庫應用程序”,它提供關于使用J b u i l d e r的D a t a E x p r e s s數據 庫體系結構的信息,并解釋原始數據組件和類之間的相互關系,以及怎樣使用它 們來創建你的數據庫應用程序。它還解釋怎樣使用Data Modeler(數據模型器)和 Application Generator(應用程序生成器)創建數據驅動的客戶機/服務器應用程 序。 • 第二部分是“開發分布式應用程序”,它提供關于使用ORB Explorer、用J B u i l d e r 創建多級的分布應用程序、調試分布式應用程序、用J a v a定義C O R B A接口以及 使用s e r v l e t等的信息。 • 第三部分是“創建J a v a B e a n”,它解釋怎樣開發新的J a v a B e a n組件,描述在組件 開發中涉及的任務, 怎樣使用B e a n s E x p r e s s創建新的J a v a B e a n,以及關于屬性、 事件、B e a nIn f o類和其他方面的詳細情況。
上傳時間: 2014-01-03
上傳用戶:wpt
數據結構 1、算法思路: 哈夫曼樹算法:a)根據給定的n個權值{W1,W2… ,Wn }構成 n棵二叉樹的集合F={T1,T2…,T n },其中每棵二叉樹T中只有一個帶權為W i的根結點,其左右子樹均空;b)在F中選取兩棵根結點的權值最小的樹作為左右子樹構造一棵新的二叉樹,且置新的二叉樹的根結點的權值為其左、右子樹上結點的權值之和;c)F中刪除這兩棵樹,同時將新得到的二叉樹加入F中; d)重復b)和c),直到F只含一棵樹為止。
上傳時間: 2016-03-05
上傳用戶:lacsx
簡單的floyd運用 第一行輸入一個整數C。C是測試的情況(0< C <=30).第二行一個正整數N( 0< N <=100),表示道路的總數.緊接N行,每一行包含兩個字符串, Si,,Ti,和一個整數Di,代表從Si到Ti的距離(0<= Di <=150)。最后一行有兩個字符串,S 和 T,你得找出從S 到 T的最短的距離。地名是不超過120個小寫字符的串(從‘a’到‘z’)。假設這里最多有100條直接連通兩個地方的路。 Output 輸出包含C行,每一行對一種測試情況。對每一種測試情況,輸出包含一個整數,假如S 到 T存在一條最短的路,輸出從S到T的最短距離,否則輸出“-1”. Sample Input 2 2 jiuzhouriver liuchi 89 liuchi liyuan 100 liuchi jiuzhouriver 3 youyongchi fengyuan 100 qinshi meiyuan 100 chaochang supermarkt 100 meiyuan youyongchi Sample Output 89 -1
上傳時間: 2016-03-10
上傳用戶:wyc199288
實現最優二叉樹的構造;在此基礎上完成哈夫曼編碼器與譯碼器。 假設報文中只會出現如下表所示的字符: 字符 A B C D E F G H I J K L M N 頻度 186 64 13 22 32 103 21 15 47 57 1 5 32 20 57 字符 O P Q R S T U V W X Y Z , . 頻度 63 15 1 48 51 80 23 8 18 1 16 1 6 2 要求完成的系統應具備如下的功能: 1.初始化。從終端(文件)讀入字符集的數據信息,。建立哈夫曼樹。 2.編碼:利用已建好的哈夫曼樹對明文文件進行編碼,并存入目標文件(哈夫曼碼文件)。 3.譯碼:利用已建好的哈夫曼樹對目標文件(哈夫曼碼文件)進行編碼,并存入指定的明文文件。 4.輸出哈夫曼編碼文件:輸出每一個字符的哈夫曼編碼。
上傳時間: 2014-11-23
上傳用戶:shanml