- 博客(3)
- 收藏
- 关注
原创 二维数组查找
int num[][4]={1,2,8,9,2,4,9,12,4,7,10,13,6,8,11,15}; bool find(int*matrix,int columns,int rows,int value) { if(matrix==NULL||columns<=0||rows<=0) return false; else { int row=0; int column=c
2015-04-04 00:26:55
233
原创 将一个二叉树镜像
// test.cpp : 定义控制台应用程序的入口点。 // #include "stdafx.h" #include #include #include using namespace std; typedef struct BTreeNode { char Value; BTreeNode* Left; BTreeNode* Right; }BTreeNode; void
2015-04-03 21:09:14
268
原创 在一个字符串中找到第一个只出现一次的字符
#include #include #include using namespace std; void FirstNotrepeating(string& str) { int i; map NumOfChar; if(str=="") { cout<<"null!"; return; } for(i=0;str[i]!='\0';i++) { NumOfC
2015-03-17 10:18:06
328
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人