上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 20 下一页
摘要: static std::string current(); Returns the current working directory. int depth() const; Returns the number of directories in the directory list. const 阅读全文
posted @ 2017-04-24 11:00 于光远 阅读(1187) 评论(0) 推荐(0)
摘要: 基于入门的环境及makefile。 void copyTo(const std::string & path)const; 将该文件复制到某个目录,将文件内容复制到指定文件。 void createDirectories(); 创建所有的目录,即使目录的父目录不存在 bool createDirec 阅读全文
posted @ 2017-04-21 14:52 于光远 阅读(3065) 评论(0) 推荐(0)
摘要: 源码按照poco。然后看README,进行安装。 ./configure make make install makefile makefile 出现错误,请注意命令行后的tab键。 阅读全文
posted @ 2017-04-21 09:15 于光远 阅读(481) 评论(0) 推荐(0)
摘要: Makefile中wildcard的介绍 在Makefile规则中,通配符会被自动展开。但在变量的定义和函数引用时,通配符将失效。这种情况下如果需要通配符有效,就需要使用函数“wildcard”,它的用法是:$(wildcard PATTERN...) 。在Makefile中,它被展开为已经存在的、 阅读全文
posted @ 2017-04-20 18:52 于光远 阅读(5150) 评论(0) 推荐(0)
摘要: cgroups 命令集 最后介绍,功能最为强大的控制组(cgroups)的用法。cgroups 是 Linux 内核提供的一种机制,利用它可以指定一组进程的资源分配。 具体来说,使用 cgroups,用户能够限定一组进程的 cpu 占用率、系统内存消耗、网络带宽,以及这几种资源的组合。 对比nice 阅读全文
posted @ 2017-04-18 14:56 于光远 阅读(1920) 评论(0) 推荐(0)
摘要: class A{public: typedef int (*func)(int); operator func();};int ff(int a){ return a;}A::operator func(){ return ff;}int main () { cout<< A::func(9)<<e 阅读全文
posted @ 2017-04-07 19:01 于光远 阅读(326) 评论(0) 推荐(0)
摘要: 有道英语:http://xue.youdao.com/sw/m/1302569 最美英文诗篇NO.27 The last time 《最后一次》 From the moment you hold your baby in your arms, you will never be the same. 阅读全文
posted @ 2017-02-14 08:54 于光远 阅读(585) 评论(0) 推荐(0)
摘要: 1.有数组penny,penny中所有的值都为正数且不重复。每个值代表一种面值的货币,每种面值的货币可以使用任意张,再给定一个整数aim(小于等于1000)代表要找的钱数,求换钱有多少种方法。 给定数组penny及它的大小(小于等于50),同时给定一个整数aim,请返回有多少种方法可以凑成aim。 阅读全文
posted @ 2016-12-04 22:17 于光远 阅读(1731) 评论(0) 推荐(0)
摘要: 1题目描述 输入一个链表,输出该链表中倒数第k个结点。 /* struct ListNode { int val; struct ListNode *next; ListNode(int x) : val(x), next(NULL) { } };*/ class Solution { public 阅读全文
posted @ 2016-12-03 09:36 于光远 阅读(283) 评论(0) 推荐(0)
摘要: 对于一个int数组,请编写一个冒泡排序算法,对数组元素排序。 给定一个int数组A及数组的大小n,请返回排序后的数组。 测试样例: [1,2,3,5,2,3],6 [1,2,2,3,3,5]冒泡: 依次比较相邻,大的放后面。 class BubbleSort { public: int* bubbl 阅读全文
posted @ 2016-12-02 23:41 于光远 阅读(506) 评论(0) 推荐(0)
上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 20 下一页