码迷,mamicode.com
首页 >  
搜索关键字:decode ways    ( 3811个结果
Android图像处理之Bitmap类
Bitmap是Android系统中的图像处理的最重要类之一。用它可以获取图像文件信息,进行图像剪切、旋转、缩放等操作,并可以指定格式保存图像文件。本文从应用的角度,着重介绍怎么用Bitmap来实现这些功能。一、Bitmap的生成1.1 BitmapFactory decode出Bitmap Bitm...
分类:移动开发   时间:2015-04-30 00:46:33    阅读次数:220
leetcode 70 Climbing Stairs
Climbing Stairs                       You are climbing a stair case. It takes n steps to reach to the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you...
分类:其他好文   时间:2015-04-29 19:52:44    阅读次数:117
啊哈!算法:解密QQ号
书中给出的算法有点浪费空间,可以使用循环队列进行改进,这样就不需要使用额外的空间,在原数组的基础上就可以完成解密,代码如下: 1 #include 2 3 void decode(int a[], int size) 4 { 5 int head = 0, tail = size;//t...
分类:编程语言   时间:2015-04-29 17:00:07    阅读次数:160
POJ 2506 Tiling (递推+高精度)
【题目链接】click here~~ 【题目大意】 In how many ways can you tile a 2xn rectangle by 2x1 or 2x2 tiles?  Here is a sample tiling of a 2x17 rectangle.  【解题思路】: (1)一个2*2的格子有三种填充方法: 两个横着放, 两个竖着放, 放一...
分类:其他好文   时间:2015-04-29 11:53:06    阅读次数:134
HDU 3544 (不平等博弈) Alice's Game
切巧克力的游戏,想得还是不是太明白。后者会尽量选前着切后其中小的一块来切,那么先手须尽量取中间来切。So?题解都是这么一句话,不知道是真懂了还是从别人那抄过来的。后来找到一个官方题解,分析得比较认真,但我这智商还是没懂太多,QAQ本题我抄袭自《Winning Ways for your Mathem...
分类:其他好文   时间:2015-04-28 15:49:36    阅读次数:124
PHP解析JSON和XML方法
一、JSON$r = json_decode({"code":200,"result":[这里是json数据]}); $result = $r->result; //就是你的数据json解析后,虽然是类似数组形式,但是需要通过->符号访问,不能通过[]形式访问,同样可以做遍历等操作二、XML...
分类:Web程序   时间:2015-04-28 09:28:17    阅读次数:125
Decode Ways -- leetcode
A message containing letters from A-Z is being encoded to numbers using the following mapping: 'A' -> 1 'B' -> 2 ... 'Z' -> 26 Given an encoded message containing digits, determine the total nu...
分类:其他好文   时间:2015-04-27 15:16:14    阅读次数:124
python 处理抓取网页乱码
python 处理抓取网页乱码问题一招鲜相信用python的人一定在抓取网页时,被编码问题弄晕过一阵前几天写了一个测试网页的小脚本,并查找是否包含指定的信息。在html = urllib2.open(url).read() 时,打印到控制台始终出现乱码。一般的解决办法就是html.decode('u...
分类:编程语言   时间:2015-04-27 14:52:22    阅读次数:175
JSONModel的使用详解
JSONModel is a data model framework for iOS and OSX. It's written in Objective-C and helps you in several different ways.You can read more about its k...
分类:Web程序   时间:2015-04-27 00:22:53    阅读次数:322
【Climbing Stairs】cpp
题目:You are climbing a stair case. It takesnsteps to reach to the top.Each time you can either climb 1 or 2 steps. In how many distinct ways can you cl...
分类:其他好文   时间:2015-04-26 18:17:40    阅读次数:92
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!