• 博客园logo
  • 会员
  • 周边
  • 新闻
  • 博问
  • 闪存
  • 众包
  • 赞助商
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
frankM
天下武功,唯快不破。
博客园 | 首页 | 新随笔 | 新文章 | 联系 | 订阅 订阅 | 管理

01 2015 档案

 
LeetCode Integer to Roman
摘要:链接: https://oj.leetcode.com/problems/integer-to-roman/题目上已经说最大出现的整型值为3999,这样就很简单了。class Solution{ public: string intToRoman(int num) { string ans;... 阅读全文
posted @ 2015-01-31 20:42 frankM 阅读(112) 评论(0) 推荐(0)
Container With Most Water
摘要:链接: https://oj.leetcode.com/problems/container-with-most-water/尺取法,从两端向中间缩进class Solution{ public: int maxArea(vector &height) //尺取法 { int L=0; ... 阅读全文
posted @ 2015-01-29 15:02 frankM 阅读(127) 评论(0) 推荐(0)
LeetCode ZigZag Conversion
摘要:链接: https://oj.leetcode.com/problems/zigzag-conversion/题意为:把字符串按如下规则排列AGMBFHLNCEIK:DJ:输出按行顺序:AGMBFHLNCEIKDJ剩下的就是通过字符的坐标计算在字符串中的位置了class Solution{ publ... 阅读全文
posted @ 2015-01-28 01:34 frankM 阅读(139) 评论(0) 推荐(0)
LeetCode 5 最长回文子串 Manacher线性算法
摘要:题目链接:https://oj.leetcode.com/problems/longest-palindromic-substring/回文串即正向反向序列都一样的连续序列 如abba,abcba...为了统一回文串的偶数情况和奇数情况,可以向串中插入不相关的字符,例如abba->#a#b#b#a#... 阅读全文
posted @ 2015-01-26 12:19 frankM 阅读(220) 评论(0) 推荐(0)
LeetCode Longest Substring Without Repeating Characters
摘要:链接: https://oj.leetcode.com/problems/longest-substring-without-repeating-characters/字符串中最长连续不重复子序列,用JAVA中的哈希表比较方便public class Solution { public int... 阅读全文
posted @ 2015-01-22 23:50 frankM 阅读(125) 评论(0) 推荐(0)
Add Two Numbers
摘要:链接:https://oj.leetcode.com/problems/add-two-numbers/链表的大数加法/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode ... 阅读全文
posted @ 2015-01-20 20:08 frankM 阅读(124) 评论(0) 推荐(0)
vim 常用插件的安装
摘要:安装如下几个插件taglist 以分割窗口显示代码结构预览 下载地址:http://www.vim.org/scripts/script.php?script_id=273stl STL语法高亮 下载地址:http://www.vim.org/scripts/script.php?script_id... 阅读全文
posted @ 2015-01-20 14:48 frankM 阅读(699) 评论(0) 推荐(0)
LeetCode Swap Nodes in Pairs
摘要:链接:https://oj.leetcode.com/problems/swap-nodes-in-pairs/交换链表相邻的节点的位置/** * Definition for singly-linked list. * struct ListNode { * int val; * ... 阅读全文
posted @ 2015-01-18 14:24 frankM 阅读(129) 评论(0) 推荐(0)
LeetCode Majority Element
摘要:链接: https://oj.leetcode.com/problems/majority-element/LeetCode给的这道题的解答真的不错:Runtime: O(n2) — Brute force solution: Check each element if it is the majo... 阅读全文
posted @ 2015-01-16 20:02 frankM 阅读(119) 评论(0) 推荐(0)
10 Open Source Security Tools from Google, Facebook, Netflix and Cisco
摘要:原文地址:http://www.linux.com/news/software/applications/797378-10-open-source-security-software-tools源自Google,Facebook,Netflix和Cisco的十个开源安全工具Choicehaslon... 阅读全文
posted @ 2015-01-11 15:49 frankM 阅读(285) 评论(0) 推荐(0)
JAVA基础课程设计 简易坦克大战
摘要:工程的结构如下:类名父类/接口功能Palyvoid音频播放Wel_PanelJPanel欢迎界面keylistenerKeyAdapter键盘监听PC_tankRunnable电脑坦克的控制T_BulletRunnable子弹的控制Testvoid主函数入口各类的组装A_tankJPanel左方向坦... 阅读全文
posted @ 2015-01-09 20:00 frankM 阅读(432) 评论(0) 推荐(0)
JAVA基础课程设计 简易扫雷
摘要:以下每行代码,文字均为原创,转载请注明出处.程序一共分为7个文件,每个文件为一个类文件名功能描述Test.java测试类,包含main()函数Mine.java设计主界面,Calmine.java随机雷的位置.计算雷区点击后应该显示的数字My_button.java继承自button类,添加按钮的坐... 阅读全文
posted @ 2015-01-03 17:00 frankM 阅读(596) 评论(0) 推荐(0)
LeetCode Evaluate Reverse Polish Notation
摘要:链接: https://oj.leetcode.com/problems/evaluate-reverse-polish-notation/后缀表达式求值class Solution{ public: int evalRPN(vector &tokens) { stack stk; in... 阅读全文
posted @ 2015-01-01 10:47 frankM 阅读(141) 评论(0) 推荐(0)
 

公告


博客园  ©  2004-2026
浙公网安备 33010602011771号 浙ICP备2021040463号-3