1.关于set
C++ STL 之所以得到广泛的赞誉,也被很多人使用,不只是提供了像vector, string, list等方便的容器,更重要的是STL封装了许多复杂的数据结构算法和大量常用数据结构操作。vector封装数组,list封装了链表,map和set封装了二叉树等,在封装这些数据结构的时候,STL按照程序员的使用习惯,以成员函数方式提供的常用操作,如:插入、排序、删除、查找等。让...
分类:
其他好文 时间:
2015-03-16 16:36:21
阅读次数:
261
with Ada.Text_IO; use Ada.Text_IO;
procedure Main is
type func_ptr is access procedure ( args : in String );
procedure callee( msg : in String ) is
begin
Ada.Text_IO.Put...
分类:
其他好文 时间:
2015-03-16 16:31:41
阅读次数:
175
1、创建要下载数据的实体类 class MyData
{
String imagepath;
String title;
String desc; public MyData(String imagepath, String title, String desc)
{
super();...
分类:
移动开发 时间:
2015-03-16 16:28:59
阅读次数:
175
有N道题,要求得到最少W分
给出N道题的:每道题用时T,分数V,应在且必须在L时刻提交才能得分
问得到W分所用的最少的时间
以L-T排序,然后做01背包即可
#include "stdio.h"
#include "algorithm"
#include "string.h"
using namespace std;
struct Mark
{
int t,v,l...
分类:
其他好文 时间:
2015-03-16 16:27:55
阅读次数:
75
创建类Python 类使用 class 关键字来创建。简单的类的声明可以是关键字后紧跟类名:class ClassName(bases):
'class documentation string' #'类文档字符串'
class_suite #类体实例化通过类名后跟一对圆括号实例化一个类
mc = MyClass() # instantiate class 初始化类‘int...
分类:
编程语言 时间:
2015-03-16 16:27:44
阅读次数:
177
problem:
Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters for "abcabcbb" is "abc", which the length...
分类:
编程语言 时间:
2015-03-16 16:25:54
阅读次数:
155
最近涉及到通过c# 对mysq数据库的备份和附件功能
因为mysql 有类似的备份和附加的cmd命令,但是一直没用过,今天实践了下,感觉效率挺快,比自己写的效率高。下面我列出c#调用mysql的备份和附加功能函数。
1.备份mysql数据库
定义string strAddress = string.Format("mysqldump --host={0} --default-char...
分类:
数据库 时间:
2015-03-16 16:22:47
阅读次数:
194
警告: Error setting expression 'myfile' with value '[Ljava.lang.String;@10c0f66'ognl.MethodFailedException: Method "setMyfile" failed for object com.zw....
分类:
编程语言 时间:
2015-03-16 16:20:24
阅读次数:
167
判断一个字符串是否是对称的 跳过所有非数字和字母,字母不分大小写 知道函数isalnum和tolower或者toupper就可以做了,两个指针一个指向头,一个指向尾,朝中间靠拢比较 空串是对称的 class Solution {public: bool isPalindrome(string s) ...
分类:
其他好文 时间:
2015-03-16 16:13:52
阅读次数:
150