码迷,mamicode.com
首页 >  
搜索关键字:palindrome linked li    ( 14538个结果
Linked List Cycle
文中用快慢指针详细分析了在有环路的链表上,两个指针会在何时、何地相遇,如何知道相遇点偏离了环路起点多远。
分类:其他好文   时间:2014-07-22 23:13:13    阅读次数:375
【leetcode刷题笔记】Remove Duplicates from Sorted List
Given a sorted linked list, delete all duplicates such that each element appear onlyonce.For example,Given1->1->2, return1->2.Given1->1->2->3->3, retu...
分类:其他好文   时间:2014-07-22 23:12:13    阅读次数:426
小结
1. //取得结果集中行的数目示例:$count = mysql_num_rows($result1);2. //小括号里odd代表奇数,even代表偶数 示例:tr:nth-child(odd){ background: #cad9ea; }3.//Mysql数据库li...
分类:其他好文   时间:2014-07-22 23:11:33    阅读次数:423
Palindrome Partitioning
Given a strings, partitionssuch that every substring of the partition is a palindrome.Return all possible palindrome partitioning ofs.For example, giv...
分类:其他好文   时间:2014-07-22 23:08:15    阅读次数:446
[leetcode]Reorder List @ Python
原题地址:http://oj.leetcode.com/problems/reorder-list/题意:Given a singly linked listL:L0→L1→…→Ln-1→Ln,reorder it to:L0→Ln→L1→Ln-1→L2→Ln-2→…You must do this...
分类:编程语言   时间:2014-05-01 15:37:03    阅读次数:441
Palindrome Partitioning II
Given a strings, partitionssuch that every substring of the partition is a palindrome.Return the minimum cuts needed for a palindrome partitioning ofs...
分类:其他好文   时间:2014-05-01 14:47:09    阅读次数:409
LeetCode OJ - Valid Palindrome
这道题挺简单的,但是需要细心。最好的方法是先对string做预处理,然后再判断是否是回文。下面是AC代码: 1 /** 2 * Given a string, determine if it is a palindrome, considering only alphanumeric ch...
分类:其他好文   时间:2014-05-01 01:45:34    阅读次数:375
文件流
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.IO; using System.Li...
分类:其他好文   时间:2014-05-01 01:02:33    阅读次数:322
six solutions to a single symmetrical problem
Problem description:given a string, find the longest palindrome string in itSolution:1.brute force O(n^3)just enumerate start and end of the substring...
分类:其他好文   时间:2014-04-29 17:22:46    阅读次数:308
C#常见算法题目
//冒泡排序publicclassbubblesorter{publicvoidsort(int[]list){inti,j,temp;booldone=false;j=1;while((jlist[i+1]){done=false;temp=list[i];list[i]=list[i+1];li...
分类:其他好文   时间:2014-04-29 17:21:45    阅读次数:429
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!