原创 [POJ] 1005 -> I Think I Need a Houseboat
I Think I Need a Houseboat Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 91306 Accepted: 39671 Des
原创 一步一步學做一個CPU——2,Logisim的簡單入門
Logisim的簡單入門 先來以一個與門電路的實驗,來看一下基本的操作,在Logisim中一個與門電路生成過程如下: 1.按與門的選擇按鈕,添加一個與門到電路中。 2.使用按鈕添加一個輸入引腳,用於設置輸入電平。 3.添加一個引
原创 【HDOJ】2034 -> 人見人愛A-B
題目鏈接:http://acm.hdu.edu.cn/showproblem.php?pid=2034 #include <iostream> #include <set> #include <algorithm> #include <
原创 STL總結
目錄 ==================================================== 第一章 容器 第二章 Vector和string 第三章 關聯容器 第四章 迭代器 第五章 算法 第六章 函
原创 【C++學習筆記】返回桌面等特系統殊路徑地址 —> SHGetSpecialFolderPath
//頭文件 #include <shlobj.h> //函數原型 BOOL SHGetSpecialFolderPath(HWND hwndOwner, //可用GetDesktopWindow API取一個窗口句柄或直接傳NULL.
原创 雙向鏈表
#include "stdafx.h" #include <iostream> using namespace std; typedef unsigned int UINT; template <class Type> struct
原创 一步一步學做一個CPU——1,準備工作
一,準備工作 參考: 羅老闆的計算機結構與組成課程 http://xgxy.cug.edu.cn/rjgcx/lzw/COD/ Machine Structures. Spring 2010, UC Berkeley http
原创 【C++學習筆記】簡單的多線程程序(摘自孫鑫C++教學視頻)
#include "stdafx.h" #include <Windows.h> #include <iostream> using namespace std; DWORD WINAPI Fun1Proc(LPVOID lpParam
原创 【C++學習筆記】計算程序運行所用的時間
秒級 #include <time.h> time_t now; time(&now); 毫秒級 #include <Windows.h> DWORD startTime = GetTickCount(); //yo
原创 【Java】UDP聊天程序
package tmp; import java.io.BufferedInputStream; import java.net.*; import java.util.Scanner; public class TmpMain im
原创 [POJ] 1004 -> Financial Management
Financial Management Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 159085 Accepted: 60480 Descript
原创 [POJ] 1003 -> Hangover
Hangover Description How far can you make a stack of cards overhang a table? If you have one card, you can create a
原创 【C++學習筆記】文件操作編程基礎
需要用到的幾個函數//************************************************************************************************************
原创 RPN算法
網上流傳的代碼思路都大體相同,我貼個簡短點的代碼,有建議請交流! #include <string> #include <sstream> #include <stack> #include <map> #include <iostre
原创 快速排序
#include <iostream> #include <iterator> using namespace std; int partion(int a[], int left, int right){ int key=a[lef