排序:
默认
按更新时间
按访问量

系统:win10 IDE:pycharm Python版本:2.7 安装第三方插件是报错: 这里写图片描述 报错原因与编码有关,pip把下载的临时文件存放在了用户临时文件中,这个目录一般是C

系统:win10  IDE:pycharm  Python版本:2.7  安装第三方插件是报错:    报错原因与编码有关,pip把下载的临时文件存放在了用户临时文件中,这个目录一般是C:\Users\用户名\AppData\Local\Temp,目录名中有中文,显然ascii这种编码是...

2017-12-01 16:04:48

阅读数:257

评论数:0

[python]解决Windows下安装第三方插件报错:UnicodeDecodeError: 'ascii' codec can't decode byte 0xcb in position 0:

系统:win10 IDE:pycharm Python版本:2.7 安装第三方插件是报错: 报错原因与编码有关,pip把下载的临时文件存放在了用户临时文件中,这个目录一般是C:\Users\用户名\AppData\Local\Temp,目录名中有中文,显然ascii这种编码是不...

2017-02-09 11:49:58

阅读数:531

评论数:0

安装第三方库出现 Python version 2.7 required, which was not found in the registry 建立一个文件 register.py 内容如下.

安装第三方库出现 Python version 2.7 required, which was not found in the registry建立一个文件 register.py 内容如下. 然后执行该脚本.import sysfrom _winreg import *# tweak as n...

2016-12-30 17:05:12

阅读数:786

评论数:0

mysql设置编码

MySQL 4.1的字符集支持(Character Set Support)有两个方面:字符集(Character set)和排序方式(Collation)。对于字符集的支持细化到四个层次: 服务器(server),数据库(database),数据表(table)和连接(connection)。 ...

2016-12-14 21:25:28

阅读数:209

评论数:0

Leetcode题解 396. Rotate Function

Given an array of integers A and let n to be its length.Assume Bk to be an array obtained by rotating the array A k positions clock-wise, we define a...

2016-10-08 15:30:38

阅读数:211

评论数:0

Leetcode题解 321. Create Maximum Number

Create Maximum Number 题目描述Given two arrays of length m and n with digits 0-9 representing two numbers. Create the maximum number of length k <= m...

2016-08-28 22:35:01

阅读数:336

评论数:0

字符串消消乐

遇到3个一样的就标记 public static void test(String s) { boolean modify = false; int len = 0; char[] re = new char[s.length()]; ...

2016-08-28 11:13:56

阅读数:679

评论数:0

Leetcode题解 15. 3Sum

Given an array S of n integers, are there elements a, b, c in S such that a + b + c = 0? Find all unique triplets in the array which gives the sum of...

2016-08-18 15:58:28

阅读数:221

评论数:0

Leetcode题解 120. Triangle

Given a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the row below.For example, given the fo...

2016-08-17 23:40:07

阅读数:163

评论数:0

Leetcode题解 122. Best Time to Buy and Sell Stock II

假设有一个数组,它的第i个元素是一个给定的股票在第i天的价格。设计一个算法来找到最大的利润。你可以完成尽可能多的交易(多次买卖股票)。然而,你不能同时参与多个交易(你必须在再次购买前出售股票)。 解题思路 在Best Time to Buy and Sell Stock系列中,和本题最像的是B...

2016-08-17 09:45:40

阅读数:605

评论数:2

Android中使用Handler造成内存泄露的分析和解决

什么是内存泄露? Java使用有向图机制,通过GC自动检查内存中的对象(什么时候检查由虚拟机决定),如果GC发现一个或一组对象为不可到达状态,则将该对象从内存中回收。也就是说,一个对象不被任何引用所指向,则该对象会在被GC发现的时候被回收;另外,如果一组对象中只包含互相的引用,而没有来自它们外部...

2016-08-16 23:45:14

阅读数:191

评论数:0

Leetcode题解 219. Contains Duplicate II

Given an array of integers and an integer k, find out whether there are two distinct indices i and j in the array such that nums[i] = nums[j] and the...

2016-08-16 00:05:44

阅读数:412

评论数:0

Leetcode题解 136. Single Number

Given an array of integers, every element appears twice except for one. Find that single one.第一种解法就是《剑指offer》上的,下面是一种通用的解法:public class Solution { ...

2016-08-11 10:53:40

阅读数:134

评论数:0

Leetcode题解 343. Integer Break

Given a positive integer n, break it into the sum of at least two positive integers and maximize the product of those integers. Return the maximum pr...

2016-07-20 18:06:37

阅读数:172

评论数:0

Leetcode题解 347. Top K Frequent Elements

Given a non-empty array of integers, return the k most frequent elements.For example, Given [1,1,1,2,2,3] and k = 2, return [1,2].用桶排序来做最后处理。public ...

2016-07-20 16:03:51

阅读数:189

评论数:0

Leetcode题解 268. Missing Number

Given an array containing n distinct numbers taken from 0, 1, 2, …, n, find the one that is missing from the array.For example, Given nums = [0, 1, ...

2016-07-20 16:02:46

阅读数:167

评论数:0

Leetcode题解 142. Linked List Cycle II

Given a linked list, return the node where the cycle begins. If there is no cycle, return null.《程序员面试金典》原题/** * Definition for singly-linked list. ...

2016-07-19 22:23:22

阅读数:162

评论数:0

Leetcode题解 141. Linked List Cycle

Given a linked list, determine if it has a cycle in it.Follow up: Can you solve it without using extra space?解法一:不用任何额外空间去做。/** * Definition for si...

2016-07-19 22:21:50

阅读数:170

评论数:0

Leetcode题解 287. Find the Duplicate Number

Given an array nums containing n + 1 integers where each integer is between 1 and n (inclusive), prove that at least one duplicate number must exist....

2016-07-19 22:11:28

阅读数:177

评论数:0

Leetcode题解 28. Implement strStr()

Implement strStr().Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.解法一:(暴力法)public class Sol...

2016-07-18 12:09:21

阅读数:224

评论数:0

提示
确定要删除当前文章?
取消 删除
关闭
关闭