码迷,mamicode.com
首页 >  
搜索关键字:find    ( 24186个结果
CodeForces 19D Points(线段树+map)
开始想不通,后来看网上说是set,就有一个想法是对每个x建一个set。。。然后又想直接建立两重的set就好,最后发现不行,自己想多了。。。 题意是给你三种操作:add (x y) 平面添加(x y)这个点 remove (x y)平面删除(x y)这个点 find (x y) 查找(x y)这个点严 ...
分类:其他好文   时间:2016-09-12 09:48:53    阅读次数:159
14. Longest Common Prefix
Write a function to find the longest common prefix string amongst an array of strings. Solution1: 思路:没有想到什么巧妙方法。就用recursion暴力硬做。发现只要想法对,recursion怎么做都能 ...
分类:其他好文   时间:2016-09-12 07:21:25    阅读次数:125
160. Intersection of Two Linked Lists
Write a program to find the node at which the intersection of two singly linked lists begins. For example, the following two linked lists: begin to in ...
分类:其他好文   时间:2016-09-12 06:15:39    阅读次数:138
113. Path Sum II
Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum. For example:Given the below binary tree and sum ...
分类:其他好文   时间:2016-09-12 00:41:41    阅读次数:120
104. Maximum Depth of Binary Tree
Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest l ...
分类:其他好文   时间:2016-09-11 23:02:10    阅读次数:142
msg: ReferenceError: Can't find variable: urchinTracker
在调试的时候发现selenium在启动浏览器打开url地址的时候报这个错误 检查了脚本发现方法就是下面的这个,很正常的 于是尝试把Url改变,把这个get的url换成了下面这个,此时界面就可以成功打开 于是我猜测,虽然【http://read.qidian.com/BookReader/vol,10 ...
分类:其他好文   时间:2016-09-11 21:33:03    阅读次数:152
HDU 5492 Find a path
题意: 在一张N*M的图上,每个点都有权值,寻找一条从(1,1)到(n,m)的路径,使得 (n+m-1)*sigma(Ai-Aavg)最小 其中Aavg是路径上Ai的平均数 题解 看题目是一个DP,但是路径平均值得存在使得状态很难定义。 所以我们进行变形,将和式展开之后,得到ans=(n+m-1)* ...
分类:其他好文   时间:2016-09-11 20:20:17    阅读次数:89
C++ 删除字符串的两种实现方式
C++实现删除给定字符串的给定字符串思路主要有这么几种实现方式: 1.KMP算法2.用STL的string的 find,然后用erase3.用C的strstr找到字串位置,然后用strncpy写到新串中4.用boost库,用正则表达式 测试过的完整代码: 第一种方法: 第二种方法,用STL 个人感觉 ...
分类:编程语言   时间:2016-09-11 18:47:05    阅读次数:154
grub修复和安装及linux系统裁剪
一.grub修复1.模拟grub.conf损坏#mvgrub.confgrub.conf.bak重启,直接进入命令行模式grub>2.手动配置grubgrub>root(hd0,0)(使用find和tab键自动补全功能,找到grub所在分区)grub>kernel/vmlinuz....roroot=/dev/root(系统自己找不到的话,只能自己凭记忆)quietgrub>..
分类:系统相关   时间:2016-09-11 15:44:40    阅读次数:252
【LeetCode】223. Rectangle Area 解题小结
题目: Find the total area covered by two rectilinear rectangles in a 2D plane. Each rectangle is defined by its bottom left corner and top right corner ...
分类:其他好文   时间:2016-09-11 10:18:56    阅读次数:125
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!