编程修养
摘要:什么是好的程序员?是不是懂得很多技术细节?还是懂底层编程?还是编程速度比较快?我觉得都不是。对于一些技术细节来说和底层的技术,只要看帮助,查资料就能找到,对于速度快,只要编得多也就熟能生巧了。 我认为好的程序员应该有以下几方面的素质: 1、有专研精神,勤学善问、举一反三。 2、积极向上的态度,有创造性思维。 3、与人积极交流沟通的能力,有团队精神。 4、谦虚谨慎,戒骄戒燥。 5、写出的代码...
阅读全文
assert的用法
摘要:#include <stdio.h>#define NDEBUG //assert影响程序性能,程序确定正确后禁用assert#include <assert.h>#include <stdlib.h>#include <iostream.h>int main( void ){char *fp=NULL;assert( fp ); //所以这里出错c...
阅读全文
遗传算法算任意表达式
摘要:#pragma warning(disable: 4786)#include <iostream> #include<fstream> #include<set> #include <string>#include <list>#include <vector>#include <math.h> #include ...
阅读全文
蚁群算法
摘要:#pragma warning(disable: 4786)#include <iostream> #include<fstream> #include<set> #include <string>#include <list>#include <vector>#include <math.h> #include ...
阅读全文
与操作神经网络算法
摘要:#include <stdlib.h>#include <math.h>#include <sstream>#include <string>#include <iostream>#include <vector>using namespace std;#define BIAS -1#define ERROR_THRESHOL...
阅读全文
多输入的神经网络算法
摘要:#include <stdlib.h>#include <math.h>#include <time.h>#include <sstream>#include <string>#include <iostream>#include <vector>using namespace std;#define BIAS -...
阅读全文
stl_string用法
摘要:#include <string>#include <iostream>using namespace std;int main(){string show;string show2="aaaa";show="bbbb";cout<<"交换两个字符串的内容"<<endl;show.swap(show2); cout<<show<&l...
阅读全文
SnmpScan
摘要:intSnmpScan(char*pAddr,char*pwd){//通过密码pwd扫描ip地址为pAddr的snmp设备,成功返回1,失败返回0Snmp::socket_startup();//Initializesocketsubsystem//---------[makeaGenAddressandOidobjecttoretrieve]---------------UdpAddressad...
阅读全文
数据挖掘经典算法
摘要:#1. C4.5Quinlan, J. R. 1993. C4.5: Programs for Machine Learning.Morgan Kaufmann Publishers Inc. #2. CARTL. Breiman, J. Friedman, R. Olshen, and C. Stone. Classification andRegression Trees. Wadsworth...
阅读全文
在matlab中描绘简单曲线和点
摘要:在MATLAB描绘y=exp(-2*t).*sin(3*t),并标出最大值点坐标clear %清除内存中的所有变量a=2; %设置衰减系数w=3; %设置振荡频率t=0:0.01:10; %取自变量采样数组y=exp(-a*t).*sin(w*t); %计算函数值,产生函数数组[y_max,i_max]=max(y); %找最大值元素位置t_text=['t=',num2str(t(i_max))...
阅读全文