算法的許多例子都是最優化問題( optimization problem),每個最優化問題都包含一組限制條件( c o n s t r a i n t)和一個優化函數( optimization function),符合限制條件的問題求解方案稱為可行解( feasible solution),使優化函數取得最佳值的可行解稱為最優解(optimal solution)。
標簽: optimization problem 算法
上傳時間: 2014-08-25
上傳用戶:123456wh
一個很好用的 lcd 時鐘程序 C語言 #include<reg51.h> #include<stdio.h> //定義計時器0 的重裝值 #define RELOAD_HIGH 0x3C #define RELOAD_LOW 0xD2 //定義按鍵彈跳時間 #define DB_VAL //定義設置模式的最大時間間隔 #define TIMEOUT 200 //定義游標位置常數 #define HOME 0 #define HOUR 1 #define MIN 2 #define SEC 3
標簽: include define RELOAD stdio
上傳時間: 2014-12-19
上傳用戶:zukfu
About WepDecrypt: Wepdecrypt is a Wireless LAN Tool written in c which guesses WEP Keys based on a active dictionary attack, key generator, distributed network attack and some other methods, it s based on wepattack and GPL licensed. WepDecrypt highlights: - Implemented packet filters. - Only one crypted packet is enough to start cracking - Has its own key generator. - Can crack a dumpfile over a network. - Can act as a server and client. - Also works in windows. - Has an fltk gui.
標簽: WepDecrypt Wepdecrypt Wireless guesses
上傳時間: 2013-12-25
上傳用戶:6546544
Embest S3C44B0X Evaluation Board RTC Test Example RTC Check(Y/N)? y Set Default Time at 2004-12-31 FRI 23:59:59 Set Alarm Time at 2005-01-01 00:00:01 ... RTC Alarm Interrupt O.K. ... Current Time is 2005-01-01 SAT 00:00:01 RTC Working now. To set date(Y/N)? y Current date is (2005,01,01, SAT). input new date (yy-mm-dd w): 5-2-23 3 Current date is: 2005-02-23 WED RTC Working now. To set time(Y/N)? y Current time is (00:00:21). To set time(hh:mm:ss): 19:32:5 Current Time is 2005-02-23 WED 19:32:
標簽: Evaluation RTC S3C44B0X Default
上傳時間: 2014-01-03
上傳用戶:baiom
牛頓法解多項式的根 輸入:多項式系數c[],多項式度數n,求在[a,b]間的根 輸出:根 要求保證[a,b]間有根
上傳時間: 2013-12-21
上傳用戶:秦莞爾w
在sco unix 下顯示前n天或后n天日期的處理程序。 printf("功能: 時間戳與時間格式字符串的轉換程序\n") printf(" -i 輸入的參數為時間戳\n") printf(" -s 輸入的參數為格式化時間\n") printf(" -t 輸入的時間取當前系統時間\n") printf(" -x 輸入的時間增加或減少的天數\n") printf(" -o 輸出的時間為時間戳格式\n") printf(" -O 輸出的時間為格式化時間\n") printf(" -h 幫助文件-查看[format]如何定義,例 %s -h\n",procname) printf("范例:1 取當前日期的前2天的時間顯示 %s -t -x -2\n",procname) printf(" 2 取20030101的前5天的時間顯示 %s -s 20030101000000 -x -5\n",procname) printf(" 3 取20031231的后5天的時間顯示 %s -s 20031231000000 -x 5 -O \"%%D %%T\"\n",procname) printf(" 4 取時間戳為1089619417的時間顯示 %s -i 1089619417 \n",procname) printf(" 5 取時間戳為1089619417的后4天的時間顯示 %s -i 1089619417 -x 4 \n",procname)
上傳時間: 2015-10-17
上傳用戶:TRIFCT
E:\Visual_C__MFC擴展編程實例 例18 動態地抓取應用程序的屏幕圖像并將其打印。 上一個實例打印的是文檔的報表,而不是當前出現在屏幕上的內容。在本例中,將實現 屏幕抓取并打印其內容。M F C 為打印視提供了有限的支持, 但只要用M F C 在 C Vi e w : : O n D r a w ( )中所提供的設備環境,就可以繪制自己的視。在打印視的時候, M F C只需調 用具備打印機設備環境的O n D r a w ( )函數即可。但是,如果不繪制自己的視,例如,用一個或 者一個以上的控件窗口填充自己的視就不會打印任何東西。每個控件將使用自己的設備環境 將自己打印到屏幕,因此打印視的唯一途徑就是抓取屏幕(拷貝其內容到一個位圖對象)并將其 打印到打印機。由于該功能整個與位圖相關,因此將該功能封裝到了位圖類中。
上傳時間: 2015-10-18
上傳用戶:asddsd
acm HDOJ 1051WoodenSticks Description: There is a pile of n wooden sticks. The length and weight of each stick are known in advance. The sticks are to be processed by a woodworking machine in one by one fashion. It needs some time, called setup time, for the machine to prepare processing a stick. The setup times are associated with cleaning operations and changing tools and shapes in the machine. The setup times of the woodworking machine are given as follows: (a) The setup time for the first wooden stick is 1 minute. (b) Right after processing a stick of length l and weight w , the machine will need no setup time for a stick of length l and weight w if l<=l and w<=w . Otherwise, it will need 1 minute for setup.
標簽: WoodenSticks Description length wooden
上傳時間: 2014-03-08
上傳用戶:netwolf
經典C語言程序設計100例1-10 如【程序1】 題目:有1、2、3、4個數字,能組成多少個互不相同且無重復數字的三位數?都是多少? 1.程序分析:可填在百位、十位、個位的數字都是1、2、3、4。組成所有的排列后再去 掉不滿足條件的排列。 2.程序源代碼: main() { int i,j,k printf("\n") for(i=1 i<5 i++) ?。?以下為三重循環*/ for(j=1 j<5 j++) for (k=1 k<5 k++) { if (i!=k&&i!=j&&j!=k) /*確保i、j、k三位互不相同*/ printf("%d,%d,%d\n",i,j,k) } }
上傳時間: 2013-12-14
上傳用戶:hfmm633
給定n 個整數n a , a , ,a 1 2 組成的序列,試設計一個O(n)時間算法,計算其最大覆蓋區間長度。
上傳時間: 2015-10-23
上傳用戶:ZJX5201314