(一)
当多个进程企图对共享数据进行某种处理,而最后的结果又取决于进程运行的顺序时,就认为它们发生了竞争关系。避免竞争的条件,给出apue上的一个代码吧:
#include "apue.h"
static void charatatime(char *);
int
main(void)
{
pid_t pid;
TELL_WAIT(); /*set things up for TEL...
分类:
系统相关 时间:
2014-05-15 12:20:22
阅读次数:
408
在android的应用层中,涉及到很多应用框架,例如:Service框架,Activity管理机制,Broadcast机制,对话框框架,标题栏框架,状态栏框架,通知机制,ActionBar框架等等。
下面就来说说经常会使用到通知机制中的通知栏框架(Notificaiton),它适用于交互事件的通知。它是位于顶层可以展开的通知列表。它会时不时的提醒你什么软件该更新了,什么人发你微信消息了等。
(...
分类:
移动开发 时间:
2014-05-15 12:14:36
阅读次数:
473
几个单词
Hierarchy
['ha??rɑ?k?]
n. 层级
思考:每个视图有一个父视图,有0个或者多个子视图
Manipulation
[m?,n?pj?'le??(?)n] n.
操纵;操作
Descendant
[d?'send(?)nt]
n. 后裔;子孙
UIWindow
Feature:
1、UIWindow set up...
分类:
其他好文 时间:
2014-05-15 12:13:20
阅读次数:
430
Two SumGiven an array of integers, find two
numbers such that they add up to a specific target number.The function twoSum
should return indices of the...
分类:
其他好文 时间:
2014-05-15 10:48:59
阅读次数:
322
The modernization of world had led to coming of
many businesses online. Businesses have realized the importance of coming up
online. That is the main ...
分类:
其他好文 时间:
2014-05-15 10:14:55
阅读次数:
364
LeetCode-001 Two Sum
Given an array of integers, find two numbers such that they add up to a specific target number.
The function twoSum should return indices of the two numbers such that they add up to the target, where index1 must be less than index2...
分类:
其他好文 时间:
2014-05-15 04:34:50
阅读次数:
293
我其实想修改的上面的蓝色条条,改成红色。
这个问题实在是困扰我了太长时间。之前参照google的这个文章:
https://developer.android.com/training/basics/actionbar/styling.html
但是事与愿违,我发现竟然连我整个tab颜色都改了。
觉得很奇怪,为什么google给的方法是修改整个tab?难道google搞错了?...
分类:
移动开发 时间:
2014-05-15 03:49:32
阅读次数:
401
Linked List Cycle
Total Accepted: 17148 Total
Submissions: 49300My Submissions
Given a linked list, determine if it has a cycle in it.
Follow up:
Can you solve it without using extra sp...
分类:
其他好文 时间:
2014-05-15 00:13:50
阅读次数:
279
[ 问题: ]
Given an array of integers, find two numbers such that they add up to a specific target number.
The function twoSum should return indices of the two numbers such that they add up to the ta...
分类:
其他好文 时间:
2014-05-15 00:04:39
阅读次数:
377
Linked List CycleGiven a linked list, determine
if it has a cycle in it.Follow up:Can you solve it without using extra
space?做完Linked List Cycle II在做这...
分类:
其他好文 时间:
2014-05-14 23:30:00
阅读次数:
399