03 2016 档案

摘要:Given a sorted array of integers, find the starting and ending position of a given target value. Your algorithm's runtime complexity must be in the or 阅读全文
posted @ 2016-03-25 14:19 梦幻之海 阅读(158) 评论(0) 推荐(0)
摘要:中国电信2016年IT研发工程师笔试题 12 给定一个已经排好序的字符串数组,空字符串散布在该数组中,编写一个函数寻找一个 给定字符串的位置。 解法:循环搜索第一个字符,第一个匹配则进行统计个数,当匹配个数等于子串长度时,则可以输出位置。 用到的知识点:1.指针地址+1,等于地址移动所属字符类型长度 阅读全文
posted @ 2016-03-03 21:04 梦幻之海 阅读(256) 评论(0) 推荐(0)
摘要:#include <stdlib.h> #include <math.h> #include <windows.h> const double PI = 3.1415926; const int count = 200; const double w = 0.01; const int value 阅读全文
posted @ 2016-03-03 10:12 梦幻之海 阅读(318) 评论(0) 推荐(0)