int cvCreateTrackbar(const char* trackbar_name, //滑动条的名称const char* window_name, //窗口的名称,滑动条不会遮挡图像int* value, //当滑动条被拖到时,OpenCV会自动将当前位置所代表的值传给指针指向的整数i...
分类:
其他好文 时间:
2014-07-16 23:05:40
阅读次数:
196
sscanf和sprintf是scanf和printf家族用法sscanf和sprintf是scanf和printf家族的一对成员,用于处理和分析字符串非常强大得两个函数头文件 stdio.h原型int sscanf(const char *buffer,const char *format,......
分类:
其他好文 时间:
2014-07-16 22:59:38
阅读次数:
200
const和readonly经常被用来修饰类的字段,两者有何异同呢? const 1、声明const类型变量一定要赋初值吗?--一定要赋初值 public class Student { public const int age; }生成的时候,会报如下错:正确的应该这样写:public class...
分类:
其他好文 时间:
2014-07-16 22:54:43
阅读次数:
166
转自:http://www.cnblogs.com/LinuxHunter/archive/2013/01/06/2848293.html#include #include #include const std::string ws2s( const std::wstring& src ){ std...
分类:
编程语言 时间:
2014-07-16 21:07:38
阅读次数:
261
这道题当时拿着一看,想都没想就上了前缀和,但看了数据范围,还是必挂的节奏。其实,应对每个前缀和取模,再桶排序一次。还有 有负数#include #include #include #include #include using namespace std;const int maxn = 50000...
分类:
其他好文 时间:
2014-07-16 20:52:38
阅读次数:
149
4.已知String类的原型是: class String { public: String(const char* str = NULL); //普通的构造函数 String(const String& that); //拷贝构造函数 ~String(void);//析构函数 Stri...
分类:
编程语言 时间:
2014-07-16 20:43:28
阅读次数:
196
使用这些格式需要声明包含long flags( ) const 返回当前的格式标志。 long flays(long newflag) 设置格式标志为newflag,返回旧的格式标志。 long setf(long bits) 设置指定的格式标志位,返回旧的格式标志。 long setf(long ...
分类:
编程语言 时间:
2014-07-16 19:59:28
阅读次数:
212
It's not the same. The const modifier can be applied to the value, or the pointer to the value.int * constA constant pointer (not modifiable) to an in...
分类:
其他好文 时间:
2014-07-12 09:04:56
阅读次数:
175
b 一.知识点1 a) 关键字volatile在编译时有什么含义?并给出三个不同使用场景的例子(可以伪代码或者文字描述)。b) C语言中static关键字的具体作用有哪些 ?c) 请问下面三种变量声明有何区别?请给出具体含义int const *p;int* const p;int const* c...
分类:
其他好文 时间:
2014-07-12 08:56:33
阅读次数:
192
题目:hdu4847:Wow! Such Doge!
题目大意:在给出的段落里面找出“doge”大小写都可以。
解题思路:字符串匹配问题,可以在之前将字母都转换成统一格式。
代码:
#include
#include
const int N = 1e6;
char str[N];
const char *s1 = "doge";
int find () {
i...
分类:
其他好文 时间:
2014-07-10 19:32:46
阅读次数:
224