原创 linux中socketaddr_in的結構解析

struct sockaddr,該類型是用來保存socket信息的: struct sockaddr { unsigned short sa_family; /* 地址族, AF_xxx */ char sa_data[14]; /*

原创 linux 的掩碼在文件和目錄的不同

關於linux的掩碼問題的學習體會 1.掩碼是創建文件是默認的模式 2.對於文件的掩碼和目錄的掩碼是不同的,例子:    掩碼002: 對於文件的掩碼是這樣的: 1.默認是777 2.但是文件創建時沒有執行權限,故去除執行權限---應該是

原创 error函數使用

/* ** 2010年11月27日 15:24:03,目的:練習error函數使用 */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <errno

原创 2010-02-27

這個寒假,過得還比較愜意,加上csdn要升級,那就是天天休息 開始上課嘍!開始有一段新的遊戲嘍!

原创 MFC_framework

#pragma once class CMainFrame: public CFrameWndEx { protected : CMainFrame(); // create function DECLARE_D

原创 better comment and better habit

/**************************************************************** function:    main description:   Main level driver. A

原创 Hash programming think twice

#include "Hash.h" int MathAscii(char * Mathparnter) { int backnumber = 0; char * move = Mathparnter; if (!Mathpar

原创 個人的認爲我的成長之路

我認爲我要學習的話,那麼我必須的先靜心,後再動,否則會出現辦事效率不高的現象,因爲這種時候我的思緒亂飛!

原创 回調函數

#include <stdio.h> void function(int number); void function_reset(int number); void function_also_reset(int number);

原创 windows socket

#include<WINSOCK2.h> #include<stdio.h> #include<stdlib.h> #include<time.h> #pragma comment(lib,"Ws2_32") #include <mmsy

原创 關於一個項目的函數的思考,及項目的規劃

接到這個項目已經大概三個星期了,總的來說在看到嚴頭生氣的沒有辦法很無語。 但是,在其中明白了不少函數,及項目建設的方法。 雖然這個程序比較小,但是讓我明白了不少函數,及程序的寫法 感悟如下: 1.首先將項目的問題描述,用自然語言,明確

原创 MFC for understanding the appcore.cpp

#include <iostream.h> class point { public: int x ; int y ; point(int a = 10, int b = 10) { x = a; y = b; }

原创 MD5個人研究

關於MD5的理解: 1.基礎:散列函數 散列函數就是一些這樣特性的函數,將一些比較離散的數據,壓縮成一個比較小的範圍內。 例如一個比較簡單的散列函數: f(x) = x mod 3; 散列函數的特點了解: 一.散列函數是函數值是有界

原创 數組指針和指針數組

這個問題主要是研究的是c語言的運算髮的結合律,對這個問題我不是很熟。 但是對於數組指針有一個我們比較習以爲常的例子: int main(int argc, char * argv[]) { }  對於這個char *argv[]便是我們

原创 think about how to make the function close to really world

I think that the software thought is make a no-really world to close the really world.   but how to make it ? I think t