自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

luofaliang

偶尔会在这里停留。

  • 博客(14)
  • 资源 (1)
  • 收藏
  • 关注

转载 Lua字符串重点函数

string.findstring.gsubstring.math

2014-08-17 18:12:19 321

原创 二进制转换成字符串

#include using namespace std;void reserve(char a[]){ int count = 0, temp = 0,max = 0; char *p = a; //指向末尾 while(*p++!='\0') { count++; } int len = max = (count+1)/4-1; int *b= new int[le

2013-10-19 19:19:12 654

原创 快速排序(递归和非递归)

#includeusing namespace std;int Partion(int *a, int l, int h){int p = a[l];while (l=high)return;int q = Partion(a,low,high);quick_sort(a,low,q-1);quick_sort(a,q+1,high);}*/// 非递归法void quick_sort(int

2013-09-27 18:17:46 472

原创 函数模板简单两例(c++)

例一:#includeusing namespace std;templatevoid display(T1 x, T2 y){ cout<<x<<" "<<y<<endl;}int main(){ char c='A'; char str[]="Hello world!"; int n=10; float x=1.5; double z=3.1415926;

2013-05-29 14:52:27 327

原创 去掉代码前的行号(行号范围 1~999)

/* 该程序用于去除代码前的序号,如在网上复制的代码每行都有序号时,序号范围适用于 1~999 */#include void main(){ char dir1[40] = {0}, dir2[40] = {0},ch[3] = {0}; FILE *fR = NULL,*fW = NULL; printf("源路径:"); gets(dir1); fR = fopen(dir

2013-05-29 13:10:30 574

转载 合并排序

#include #include #include //合并排序的合并程序他合并数组nData中位置为[nP,nM) 和[nM,nR).这个是更接近标准的思路 bool MergeStandard(int nData[], int nP, int nM, int nR) { int n1 = nM - nP; //第一个合并数据的长度 int n

2013-05-26 22:39:16 354

原创 链表的基础知识

//一直觉得学计算机归根到底都是算法。试着回忆了一下链表的知识//单向链表结构typedef struct node{ int info; struct node *next; // 再加类似这样的一条语句就是双向链表了}node;//单向链表首部插入结点node *push_front(node *head,int info){ node* p=(node *)malloc

2013-04-10 20:55:43 441

原创 求质数(C++语言)

/*刚一个同学来问我求质数的问题,我想这个问题很简单,就说百度一大堆,搜了一下,看见很多都是错误的或者即使正确效率依然很低,但要自己立马写出来也不是1+1的事情,于是就试着写了下,自我感觉不错,因为我觉得我写的这个运算效率还是比较高的。*/#include #include #include using namespace std;void main(){ int max,len=2

2013-04-10 20:35:41 585

原创 截取一句话中的单词(C语言)

#include #include int GetWordNum(char *str){ assert(str!=NULL); int num=0; char *pChar=(char*)str; while (*pChar!='\0') { char *pBegin=pChar; //每个单词的头指针 while (*pChar!=' ' && *pChar+

2013-03-24 21:12:27 1039

原创 删除特定字符串(c语言)

#include #include #include #include void Delete(char *str,char *str2){ assert(str!=NULL); int i=0,j=0,k=0; int len=strlen(str2); do { if( str[i] != str2[k] ) str[j++]=str[i]; else

2013-03-24 14:03:51 989

原创 简单的成绩排名系统

//这个程序是我自己想的,很简单,只能录入单科成绩并排名,处理了几个输入异常时情况。using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;u

2013-01-10 15:49:32 414

原创 WinForm左右移动字符串

using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace GunDo

2013-01-09 15:07:44 238

原创 c#简单的控制台个人成绩系统

using System;/**这个程序用于管理学生信息系统。要求的信息有:* 姓名,学号,专业班级,性别,所在学院,成绩,课程*/public class Person{ //设置性别,枚举类型,用 byte 定义一个性别类 public enum Sex : byte{ 男=0,女=1 } private string snumber,name,college,major

2012-12-26 22:53:51 474

原创 c#复制文件

//这个程序用于实现复制一个文件。 using System; using System.IO; class CopyFile { public static void Main(string[] args){ string s1,s2; int i ; FileStream fin,fout; Conso

2012-12-23 13:59:14 229

简单的单科成绩排名系统

就是用C#做的一个简单的单科成绩录入,可以排名,可以处理几个异常。属于WinForm

2013-01-10

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除