现在位置: 首页 > mandala发表的所有文章
  • 09月
  • 22日
综合 ⁄ 共 620字 评论关闭
CSS背景 背景色: background-color 背景图像: background-image background-image: url(...) 背景重复:  background-repeat background-repeat: repeat-x / repeat-y / no-repeat 背景定位: background-position center / top / bottom / right / left 百分制 / 长度值 背景关联:  background-attachment scroll / fixed   CSS文本 缩进文本: text-indent 水平对齐: text-align left / right / center / justify 字间距: word-spacing 字母间距: letter-spacing 字符转换: text-transform none / uppercase / lowercase / capital......
阅读全文
  • 08月
  • 09日
综合 ⁄ 共 48字 评论关闭
http://www.eefocus.com/article/09-04/71626s.html
阅读全文
  • 11月
  • 07日
综合 ⁄ 共 9025字 评论关闭
1 Tree's Advantage       Why might you want to use a tree? Usually, because it combines the advantage of two other structures: an ordered array and a linked list. You can search a tree quickly like an ordered array, as you can  also insert and delete items quickly, as you can with a linked list.     Slow insertion in an ordered array. If you want to insert a new item into an ordered array, you first need to find where the item will go, and then move  all the items with greater keys up o......
阅读全文
  • 10月
  • 09日
编程语言 ⁄ 共 407字 评论关闭
// // // // // // // // ///2012/9/30 // // // // // // // // int 假期 = 8; //回家了吗? 回家 = console.readline(); while(假期 != 0){ string 做啥子嘛 = null; string 心情 = null; if(假期 == (int)中秋节){ 做啥子嘛 += " 吃月饼"; if(回家){ 做啥子嘛 += " 陪家人" + " 赏月*R> 心情 += " 幸福"; } else{ 做啥子嘛 += " 陪基友" + " 一被子"; 心情 += " 苦逼"; } } if(假期 > 2){ 做啥子嘛 += " 呵呵..."; 心情 = " High"; } else{ 做啥子嘛 = " Saying:怎么这么快就要开学了啊啊啊啊"; 心情 = " 苦逼" ......
阅读全文
  • 06月
  • 10日
综合 ⁄ 共 302字 评论关闭
通过三步来实现一个进程内的activity通信: 1、创建关联两个activity的Intent Intent intent = new Intent(MainActivity.this,OtherActivity.this); 2、创建要传递的数据Bundle,并给Intent附加上这些数据 //Bundle类用作携带数据 Bundle bundle = new Bundle(); bundle.putString("name", "linjiqin"); bundle.putInt("age", 24); //附带上额外的数据 intent.putExtras(bundle); 3、启动:startActivity(intent);
阅读全文
  • 05月
  • 26日
综合 ⁄ 共 103字 评论关闭
1.此时不应该有goto错误   正确:set /p con=(输入1继续开启xxx.exe,输入0 退出) 错误:set /p con = (输入1继续开启xxx.exe,输入0 退出) 看出来了吧,[con=]中间不能有空格
阅读全文
  • 05月
  • 05日
综合 ⁄ 共 178字 评论关闭
将一个Java项目从一台机器的Eclipse工作环境下拷到其他机器的Eclipse工作环境下,往往会出现提示Setting build path has encountered a problem,我的解决方法是: 另外新建一个project,将该project目录下的.classpath文件替换到刚才报错的Java项目目录下,关闭Eclipse,重新打开后即为正常。
阅读全文
  • 04月
  • 23日
综合 ⁄ 共 1394字 评论关闭
主要思路就是求出序列的逆序数,此逆序数就是冒泡排序的交换次数 求逆序数采用归并排序,因为在每次归并排序中,如果左边大于右边,那么左边从此往后的数全部大于右边 code: #include <set> #include <map> #include <ctime> #include <queue> #include <cmath> #include <stack> #include <limits> #include <vector> #include <bitset> #include <string> #include <cstdio> #include <cstring> #include <fstream> #include <string.h>......
阅读全文
  • 04月
  • 12日
综合 ⁄ 共 1395字 评论关闭
Scramble String: Given a string s1, we may represent it as a binary tree by partitioning it to two non-empty substrings recursively. Below is one possible representation of s1 = "great": great / \ gr eat / \ / \ g r e at / \ a t To scramble the string, we may choose any non-leaf node and swap its two children. For example, if we choose the node "gr" and swap its two children, it produces a scrambled string "rgeat". rgeat / \......
阅读全文
  • 03月
  • 31日
综合 ⁄ 共 9668字 评论关闭
现在android应用里面下拉刷新比较多 ,今天自己研究一下相关的资料 public class MyListView extends ListView implements OnScrollListener {     private static final String TAG = "listview";     private final static int RELEASE_To_REFRESH = 0;     private final static int PULL_To_REFRESH = 1;     private final static int REFRESHING = 2;     private final static int DONE = 3;     private final static int LOADING = 4;     // 实际的padding的距离与界面上偏移距离的比例     private final static int ......
阅读全文
  • 02月
  • 13日
综合 ⁄ 共 1028字 评论关闭
       今天简单总结一些客户端app 优化的方案和方向。我相信开发一个app大部分团队都可以完成,但是性能久不一样啦,和我们都写一个冒泡算法一样,我相信每个人写的冒泡算法都不一样,这些区别就带来了性能的差别。所以一个好的app 不止看设计,和创意 ,还要看性能。下面我就简单说几点性能优化点:                    一、首页启动速度  启动过程中做的事情越少越好(尽可能将多个接口合并)  不在UI线程上作耗时的操作(数据的处理在子线程进行,处理完通知主线程刷新节目) 在合适的时机开始后台任务(例如在用户指引节目就......
阅读全文
  • 02月
  • 02日
综合 ⁄ 共 198字 评论关闭
NSString *path = [[NSBundle mainBundle] pathForResource:@"111" ofType:@"pdf"]; NSURL *url = [NSURL fileURLWithPath:path]; NSURLRequest *request = [NSURLRequest requestWithURL:url]; [self.webView loadRequest:request];
阅读全文