自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(14)
  • 资源 (20)
  • 收藏
  • 关注

原创 Top 150 Questions - 2.5

2.5 Given a circular linked list, implement an algorithm which returns node at the beginning of the loop. DEFINITION: Circular linked list: A (corrupt) linked list in which a node’s next pointer point

2012-04-30 16:07:46 1003 1

原创 Top 150 Questions - 2.4

2.4 You have two numbers represented by a linked list, where each node contains a single digit. The digits are stored in reverse order, such that the 1’s digit is at the head of the list. Write a func

2012-04-30 10:40:50 891

原创 Top 150 Questions - 2.3

2.3 Implement an algorithm to delete a node in the middle of a single linked list, given only access to that node. EXAMPLE: Input: the node ‘c’ from the linked list a->b->c->d->e; Result: nothing is r

2012-04-25 00:05:42 924

原创 Top 150 Questions - 2.2

2.2 Implement an algorithm to find the nth to last element of a singly linked list.两个指针间距n-1,后一个指针走到底时返回第一个指针即可,注意要检查cur是否为空,防止n过大。package Question2_2;public class Question2_2{ public stat

2012-04-24 23:38:01 838

原创 Top 150 Questions - 2.1

2.1 Write code to remove duplicates from an unsorted linked list. FOLLOW UP: How would you solve this problem if a temporary buffer is not allowed?RemoveDuplicate1()使用了Java的Hashtable,如果发现了duplicate,

2012-04-24 22:52:58 1016

原创 Top 150 Questions - 1.8

1.8 Assume you have a method isSubstring which checks if one word is a substring of another. Given two strings, s1 and s2, write code to check if s2 is a rotation of s1 using only one call to isSubstr

2012-04-23 23:13:22 884

原创 Top 150 Questions - 1.7

1.7 Write an algorithm such that if an element in an MxN matrix is 0, its entire row and column is set to 0.SetZero1()先扫描一次数组,记录下0元素的位置,然后进行设置。由于行列同时记录,那么同一行或列可能被设置多次,因此在SetZero2()中对行列分开存储。package

2012-04-16 12:38:44 823

原创 Top 150 Questions - 1.6

1.6 Given an image represented by an NxN matrix, where each pixel in the image is 4 bytes, write a method to rotate the image by 90 degrees. Can you do this in place?这个题看到4 bytes的时候以为要考移植性,不过既然用java

2012-04-16 10:37:18 1033

原创 Top 150 Questions - 1.5

1.5 Write a method to replace all spaces in a string with ‘%20’.package Question1_5;public class Question1_5{ public static void main(String[] args) { Question1_5 q = new Question1_5();

2012-04-15 17:41:54 1105

原创 Top 150 Questions - 1.4

1.4 Write a method to decide if two strings are anagrams or not.这个题目最简单的方法应该就是排序了吧,排序偷懒了,直接用的api;另外一个就是计算每个字符出现的次数。package Question1_4;import java.util.Arrays;public class Question1_4{

2012-04-15 17:09:57 4067 1

原创 Top 150 Questions - 1.3

1.3 Design an algorithm and write code to remove the duplicate characters in a string without using any additional buffer. NOTE: One or two additional variables are fine. An extra copy of the array is

2012-04-15 15:58:50 1179 2

原创 Top 150 Questions - 1.2

2.1 Write code to reverse a C-Style String. (C-String means that “abcd” is represented as five characters, including the null character.)C的字符串有段时间没用过了,出了几个问题。1. 在计算右边界时,需要记录s的位置,不能*s++;同时right要自减,否则

2012-04-14 22:42:42 982

原创 Top 150 Questions - 1.1

1.1 Implement an algorithm to determine if a string has all unique characters. What if you can not use additional data structures?这个题主要操作集中在查找上面,所以首先想到的就是哈希,时间复杂度为O(n);字符不超过256,定义256大小的数组就ok了。书上指出的其

2012-04-14 21:35:24 1060

原创 D12一些注意事项

在D12枚举时老是复位,很郁闷。看到网上经常有人出这个问题,但是没解答,经过仔细研究终于解决,这里我把可能有的问题都列出来。1.单片机的中断应设置为电平触发,中断后一定要读上次传输状态寄存器(命令40-45H),以清除中断寄存器中的中断标志。这样, PDIUSBD12的中断输出才能变回高电平,这一点非常重要。2.在接收到Setup包后,一定要调用ACK setup命令重新使能端口0。

2011-01-12 14:46:00 456

Windows驱动开发技术详解 part15

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part14

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part13

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part12

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part11

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part10

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part9

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part8

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part7

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part6

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part5

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part4

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part3

Windows驱动开发技术详解从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part2

Windows驱动开发技术详解 从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

Windows驱动开发技术详解 part1

Windows驱动开发技术详解 从第一章到第二十三章完整收录,由于较清晰比较大,分成了15个包 不好意思

2011-01-17

卡尔曼滤波C源程序代码

自己写的卡尔曼滤波C程序、包括需要用到的矩阵运算 注释中包括对卡尔曼滤波公式和各个变量的作用的解释 程序用示波器测试可用

2010-12-07

二级上机常用库函数和上机题型

上机资料为常用库函数 以及上机题型的分类整理

2010-03-19

C语言实现数字滤波算法

总结了常用的数字滤波算法 用C语言实现

2010-03-19

LCD12864的贪食蛇游戏

用1138写的贪食蛇程序, LCD使用的是12864, 有很详细的注释

2010-02-25

DSP驱动TLV320AIC23B的程序

利用TMS320VC5502驱动TLV320AIC23B 程序结构使用了C55X的CSL方式

2010-02-25

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除