http://poj.org/problem?id=1276有一個Cash Machine,裡面裝有t種面值為n[i]的貨幣,每種有v[i]張。問在所換金額不超過cash元錢的情況下,所能換取的最大金額。 多重背包,轉換成01背包來做,其中要用到二進位最佳化。《背包九講》上講的挺不錯,在每件物品價值前加上係數,並保證這些係數的組合包括1..n的所有數且總和為n。代碼:#include<cstdio>#include<cstring>#define Max(a, b)
在伺服器中裝Windows 2003 server EE R2版系統後,安裝VMware server 2.0,右鍵點擊安裝程式後選擇run as,程式啟動,進度條走到頭就報error: the system administrator has set policies to prevent this installation(系統管理員設定了系統策略,禁止進行此安裝)。百度、google該錯誤得到的結果大都是:由於軟體第一次安裝後沒有卸載乾淨,造成第二次安裝時留有上次安裝資訊,從而產生該錯誤。
Using Ldp.exe to Find Data in the Active DirectoryThis article applies to Windows 2000. Support for Windows 2000 ends on July 13, 2010. The Windows 2000 End-of-Support Solution Center
In previous tutorials, I learned how to view an HTTPS server certificate and its certificate path. Now I want to learn how to save a server certificate to a certificate file. 1. Run Firefox 3 and go to https://login.yahoo.com. 2. Click the lock icon
在openSolaris 0906版本中系統內建了一個GNU System Monitor,這個拿來做系統效能監控很不錯。不過很可惜在Solaris 10 中並沒有內建這個東東,因此做系統效能監控,對於我這樣的菜鳥來說,也不大方便了。 先前在GNU上下載了GNU System Monitor,結果很可惜,還是沒編譯成功。 gnusystemmonitor依賴libgtop,而libgtop又依賴glib,在configure
晚上用sax解析xml,費了半天勁寫的程式一跑就報錯:SAXParseException: Content is not allowed in prolog. 上網找了半天,發現可能的原因是xml檔案被加了bom標記了.於是用editplus將xml檔案開啟,然後重新儲存為utf8無bom格式. 然後重新編譯,然後果然沒報錯了. 據說dom4j1.6解決了bom問題.不過sax呢?貌似還不行哦. 最後在補充下bom的知識: