摘要: 1.下载前三个软件: 理论上安装Perl,TCL,Bison and Flex这三个插件 实际上安装ActiveState Perl,ActiveState tcl ,MinGW 因为MinGW包括了Bison and Flex 2.安装并配置环境变量:具体配上面三个. Perl :http://j 阅读全文
posted @ 2017-02-22 10:03 岁月静好--lyr 阅读(456) 评论(0) 推荐(0) 编辑
摘要: 一、题目要求 Given a sorted array and a target value, return the index if the target is found. If not, return the index where it would be if it were inserte 阅读全文
posted @ 2017-02-12 18:09 岁月静好--lyr 阅读(117) 评论(0) 推荐(0) 编辑
摘要: 一、题目要求 Given a sorted array, remove the duplicates in place such that each element appear only once and return the new length. Do not allocate extra s 阅读全文
posted @ 2017-02-10 14:50 岁月静好--lyr 阅读(118) 评论(0) 推荐(0) 编辑
摘要: 一、题目要求: Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid. The brackets must close 阅读全文
posted @ 2017-01-22 15:04 岁月静好--lyr 阅读(134) 评论(0) 推荐(0) 编辑
摘要: 超链接传参数方式如下: <a href=xxxServlet?flag=1 target=“XX”></a> 注意:target=“XX”是用来指定在什么窗体打开。xx为该窗体的id。 在servlert中接受方式如下: String flag=request.getParameter("flag" 阅读全文
posted @ 2017-01-11 21:32 岁月静好--lyr 阅读(4213) 评论(0) 推荐(0) 编辑
摘要: 一。bison是干什么的? bison 是一个语法分析器,把用户输入的内容,根绝在.y文件中事先定义好的规则,构建一课语法分析树。(所谓的规则就是,匹配上对应字符之后,执行相应的动作。) 1.一个简单的语法例子和分析: statement :NAME '=' expression expressio 阅读全文
posted @ 2016-11-25 21:39 岁月静好--lyr 阅读(2322) 评论(0) 推荐(0) 编辑
摘要: 1.在ubutu上安装 yacc的命令: sudo apt-get install flex bison flex:词法分析器 flex是一个词法分析器。用来将一个.l文件生成一个.c程序文件。即生成一个词法分析器。然后读取输入,和正则表达式匹配,再执行相应的动作,实现了程序的功能。 我们可以发现f 阅读全文
posted @ 2016-11-24 22:03 岁月静好--lyr 阅读(34751) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h>#include<map>#include<iostream>#include<string>using namespace std;int main() { map<string, int> map;//定义 std::map<string, int> ::ite 阅读全文
posted @ 2016-11-20 15:43 岁月静好--lyr 阅读(151) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2016-11-16 20:08 岁月静好--lyr 阅读(114) 评论(0) 推荐(0) 编辑
摘要: 一。值传递 int func(int p) 值传递会在栈中开辟一块空间 p,使得p和实参的a 同值。 此时你在函数func里面对p进行任何操作都不会对原值a产生任何影响。因为a 和p本就就是两个变量只是保存的值相同而已,除此之外没有任何关系。 要向对原值操作程序使用以下两种传参方式: 二。址传递 i 阅读全文
posted @ 2016-11-06 20:22 岁月静好--lyr 阅读(362) 评论(0) 推荐(1) 编辑