iOS的本地通知服务需要使用NSLocalNotification,处理基于时间行为的通知。比如定时通知用户该学习了。使用NSLocalNotification一般需要考虑三个方面:scheduled
time:时间周期,用来指定iOS系统发送通知的日期和时间;notification type:通...
分类:
移动开发 时间:
2014-06-06 22:47:59
阅读次数:
349
原题地址:https://oj.leetcode.com/problems/best-time-to-buy-and-sell-stock-ii/题意:Say
you have an array for which theithelement is the price of a given stoc...
分类:
编程语言 时间:
2014-06-06 20:04:46
阅读次数:
400
Sort a linked list inO(nlogn) time using
constant space complexity./** * Definition for singly-linked list. * struct
ListNode { * int val; * L...
分类:
其他好文 时间:
2014-06-06 20:01:30
阅读次数:
333
When I finished reading this problem,I thought
I could solve it by scan every single subarray in the array,and the time
complexity is cubic.Every su.....
分类:
其他好文 时间:
2014-06-04 15:30:52
阅读次数:
255
longtime=System.currentTimeMillis(); System.out.println(time); SimpleDateFormatformat=newSimpleDateFormat("yyyy-MM-ddHH:mm:ss"); java.util.Dated1=newDate(time); Stringnow=format.format(d1); System.out.println(now); longt=0; try{ java.util.Dated2=format.pa..
分类:
移动开发 时间:
2014-06-04 12:51:10
阅读次数:
474
安装系统:ubuntu12.04 i386
DVDU盘启动12.04live系统连线,设置连接安装系统到硬盘“语言支持”,更新安装gnome经典界面sudo apt-get install
gnome-shell gnome-tweak-tool gnome-panel关闭unity的全局菜单sud...
分类:
系统相关 时间:
2014-06-03 16:31:35
阅读次数:
372
起因在对一堆*.tar.gz文件解压缩时,发现tar xvfz
*.tar.gz不管用,一查,原来是tar xvfz *.tar.gz会被shell给拆成tar xvfz a.tar.gz b.tar.gz
c.tar.gz,而在a.tar.gz中不存在b.tar.gz,当然会报错。解决方法是使用脚...
分类:
其他好文 时间:
2014-06-03 15:37:16
阅读次数:
306
wait的flag参数不是很明确,考虑多个进程同时结束的情况,信号时如何处理的,是否会出现覆盖情况wait的函数原型是:
#include#include pid_t wait(int *status)
进程一旦调用了wait,就立即阻塞自己,由wait自动分析是否当前进程的某个子进程已...
分类:
其他好文 时间:
2014-06-02 19:19:08
阅读次数:
233
<?php
/**
* 生成永远唯一的激活码
* @return string
*/
function create_guid($namespace = null) {
static $guid = '';
$uid = uniqid ( "", true );
$data = $namespace;
$data .= $_SERVER ['REQUEST_TIME']; //...
分类:
Web程序 时间:
2014-06-02 18:55:35
阅读次数:
327
Lotto
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 1411 Accepted Submission(s): 697
Problem Description
In a Lotto I have eve...
分类:
其他好文 时间:
2014-06-02 18:52:53
阅读次数:
396