摘要: 七种qsort排序方法一、对int类型数组排序七种qsort排序方法一、对int类型数组排序int num[100];Sample:int cmp ( const void *a , const void *b ){return *(int *)a - *(int *)b;}qsort(num,100,sizeof(num[0]),cmp);二、对char类型数组排序(同int类型)char word[100];Sample:int cmp( const void *a , const void *b ){return *(char *)a - *(int *)b;}qsort(word,10 阅读全文
posted @ 2013-03-15 21:25 WingWing111 阅读(183) 评论(0) 推荐(0) 编辑
摘要: Physics teachers in high school often think that problems given as text are more demanding than pure computations. After all, the pupils have to read and understand the problem first!So they don't state a problem like ``U=10V, I=5A, P=?" but rather like ``You have an electrical circuit that 阅读全文
posted @ 2013-03-15 15:47 WingWing111 阅读(154) 评论(0) 推荐(0) 编辑
摘要: BackgroundLucy and Lily are twins. Today is their birthday. Mother buys a birthday cake for them.Now we put the cake onto a Descartes coordinate. Its center is at (0,0), and the cake's length of radius is 100.There are 2N (N is a integer, 1 #include #include #include #include #include #include . 阅读全文
posted @ 2013-03-15 09:19 WingWing111 阅读(203) 评论(0) 推荐(0) 编辑