原创 emacs配置文件之備份(2)

(custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up,

原创 Using Django with Appengine

Using Django with Appengine Author: Shabda Raaj Version: 1 Copyright: This document is released under a Creative Com

原创 C++中數據的精度和格式控制

//精度和格式控制 #include<iostream> #include<iomanip> using namespace std; int main() { float n; cin>>setiosflags(ios::fixed

原创 More Effective C++ 讀書筆記 之 區別pointer和reference

reference不能是空,必須有初值。 通常在reference和point都適用時,reference有更好的效率(因爲reference不需要測試是否爲NULL)。 當需要指向某個東西而且決不會改指其它東西, 或是當實現一個操作符

原创 畫線算法的實現

衆所周知,VC++中畫圖算法封裝在一個重要的類CDC中。。。基本的像LineTo();MoveTo()等, 要說到畫線,其實底層的算法也不是很難。。。在這裏貼幾個代碼分享一下!(這裏只在MFC的view類OnDraw函數實現) 1、DD

原创 emacs配置文件之備份

(custom-set-variables '(column-number-mode t);顯示列號 ;'(display-time-mode t) '(size-indication-mode t) '(transient-mark-m

原创 學習GCC[轉]

  學習 GNU Compiler Collection                                                    作者:王聰 來源:www.zeuux.org GCC 的使用 GCC 常用

原创 emacs配置文件

(custom-set-variables  ;; custom-set-variables was added by Custom.  ;; If you edit it by hand, you could mess it up, s

原创 寫個簡單的makefile

有如下三個文件,我們以此來寫個基本的makefile   test.h #ifndef TEST_H_H #define TEST_H_H #include<string> #include<vector> #include<iostre

原创 學習GDB[轉]

學習使用 GNU GDB Debugger                                               作者:王聰 GDB 常用命令參考手冊 GDB 命令行參數 GDB 命令 GDB 操作提示 GD

原创 C++中IO流的基本操作

#include<iostream> #include<fstream> #include<string> #include<sstream> using namespace std; int main() { cout<<"h

原创 排序算法之簡單排序

//冒泡排序算法 void BubbleSort(int *Data,int n) { int i,j,temp; bool exchange; for(i=n-1,exchange=true;i>0 && exchange;i

原创 今天明白了一點模板函數的事情

下面這個代碼出錯:   //test.h template<typename T> void fun(T x);    //test.cpp #include "test.h" template<typename T> void fun(

原创 emacs配置文件之備份(1)

(custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up,

原创 中國剩餘定及由此解決的一個問題

我國古代數學名著《孫子算經》中,記載這樣一個問題: “今有物不知其數,三三數之剩二,五五數之剩三,七七數之剩二,問物幾何。”用現在的話來說就是:“有一批物品,3個3個地數餘2個,5個5個地數餘3個,7個7個地數餘2個,問這批物品最少有多少