1、存储分配
2、随机数生成
3、数字转换
4、环境通信
5、搜索与排序
6、整型算术
7、多字节、宽字符和字符串转换
8、时间与日期
9、区域设置
10、其它
1、存储分配
void* malloc(size_t size);
void* calloc(size_t elt_count, size_t elt_size);
void* realloc(s...
分类:
编程语言 时间:
2015-05-14 10:04:26
阅读次数:
170
#include
void convert(int n)
{
int i;
if ((i=n/10)!=0)
convert(i);
putchar(n%10+'0');
}
int main()
{
int number;
printf("\nInput an integer:");
scanf("%d",&number);
printf("Output:");
if ...
分类:
编程语言 时间:
2015-05-14 10:02:06
阅读次数:
145
/*要求:
写四个函数
void input(float arr[], int n)
void output(float arr[], int n)
void bubblesort(float arr[], int n)
int search(float arr[], int n, float num)
*/
#include
#include
#define MAXN 1000
float ...
分类:
其他好文 时间:
2015-05-14 10:01:23
阅读次数:
165
抽象类1.包含一个抽象方法的类为抽象类,抽象类要用abstract修饰,不能直接使用其实例化对象,可以声明对象。
ps:什么是抽象方法呢?就是一个只被定义,而没有实现的方法(public abstract void fun();),就是没有{….方法体…}的方法。
2.抽象类是给子类继承的,继承抽象类的子类必须覆写所有抽象方法,否则该子类还是抽象类,不能实例化对象。
3.抽象类当然不能用fin...
分类:
编程语言 时间:
2015-05-14 08:47:48
阅读次数:
142
#define WM_TRAYICON_MSG (WM_USER+100)public: afx_msg void OnBnClickedButTuo(); BOOL TrayMyIcon(BOOL bAdd=TRUE); LRESULT OnTrayCallBackMsg(WPA...
分类:
其他好文 时间:
2015-05-14 08:38:42
阅读次数:
110
1 一、计数器的基本操作 2 1> retain : +1 3 2> release :-1 4 3> retainCount : 获得计数器 5 6 二、set方法的内存管理 7 1> set方法的实现 8 - (void)setCar:(Car *)car 9 {10 if ( _c...
分类:
其他好文 时间:
2015-05-14 00:57:21
阅读次数:
86
1 public class ProducerConsumer { 2 public static void main(String[] args) { 3 SyncStack ss = new SyncStack(); 4 Producer p = new...
分类:
编程语言 时间:
2015-05-14 00:52:31
阅读次数:
131
在Android开发中我们都会遇到在一个100*100的ImageView上显示一张过大的图片,如果直接把这张图片显示上去对我们应用没有一点好处反而存在OOM的危险,所以我们有必要采用一种有效压缩方式来显示上去。private void calculateBitmapInSimpleSize() {
Bitmap _bitmap = BitmapFactory.decodeResou...
分类:
其他好文 时间:
2015-05-13 23:17:24
阅读次数:
148
1 /************ 2 十大排序算法 3 ***********/ 4 5 #include 6 #include 7 using namespace std; 8 9 typedef int T; 10 11 void swap(T &x,T &y) 12 {...
分类:
编程语言 时间:
2015-05-13 23:10:09
阅读次数:
117
二、Collections工具类
(一)概述
1、Collections:是针对集合进行操作的工具类,都是静态方法。
2、Collection和Collections的区别:
1)Collection:是单列集合的顶层接口,有子接口List和Set。
2)Collections:是针对集合操作的工具类,有对集合进行排序和二分查找的方法
(二)方法
1、方法:
1)public static void sort(List list):排序,默认情况下是自然顺序。
2)public static...
分类:
其他好文 时间:
2015-05-13 21:59:04
阅读次数:
130