问题: 给定一组硬币面值coins,和一个总价amount 求用给定面值硬币中,有多少种构成方法能构成总价。 Example 1: Input: amount = 5, coins = [1, 2, 5] Output: 4 Explanation: there are four ways to m ...
分类:
其他好文 时间:
2020-09-12 21:37:01
阅读次数:
39
本文档总结了python2->3升级过程中遇到的编码问题 1.UnicodeDecodeError:“ascii” codec cannot decode byte oxe6 in position 501:ordinal not in range 定位:从报错日志可以发现代码运行到with ope ...
分类:
编程语言 时间:
2020-09-03 16:44:23
阅读次数:
42
1. 题目信息 附件是一个文本文件,里面有658行base64编码。 2. 分析 先将附件中每行base64编码进行解码,得到一个Python脚本。但其实信息并非隐藏在解码后的数据中,而是隐藏在编码中。首先介绍base64编码的原理,当需要编码的数据剩下1或2字节时,编码与解码过程如下: 可以看到, ...
分类:
其他好文 时间:
2020-08-27 13:01:39
阅读次数:
71
JWT认证登陆方式 在学习前后端分离的过程中往往遇到的第一个问题就是登陆验证问题,以前的我们将Cookie、Session、Token,在我的学习过程中认识了JWT验证方案,纯属自己理解,有错还望大佬指出。 JWT 全称是 JSON Web Token,是目前非常流行的跨域认证解决方案. 前情回顾 ...
分类:
其他好文 时间:
2020-08-24 15:11:47
阅读次数:
58
一、异常 [root@VM_0_4_centos prometheus-grafana-linux]# docker-compose up Traceback (most recent call last): File "/usr/bin/docker-compose", line 9, in <m ...
分类:
其他好文 时间:
2020-08-05 19:45:33
阅读次数:
103
URLDecoder对参数进行解码时候,代码如: URLDecoder.decode(param,"utf-8"); 有时候会出现类似如下的错误: URLDecoder异常Illegal hex characters in escape (%) 这是因为传参有一些特殊字符,比如%号或者说+号,导致不 ...
分类:
Web程序 时间:
2020-08-05 19:43:29
阅读次数:
101
# coding: utf-8 import socket from urllib.parse import urlparse def get_url(url): url = urlparse(url) host = url.netloc path = url.path if path == "": ...
分类:
编程语言 时间:
2020-08-02 16:13:18
阅读次数:
115
翻译自:Nicklas Millard的文章《Better Software Without If-Else》, 参考:https://medium.com/swlh/5-ways-to-replace-if-else-statements-857c0ff19357 设计更好的软件,替换If-Els ...
分类:
其他好文 时间:
2020-07-30 10:52:27
阅读次数:
91
Oracle 19c Database Upgrade From 12.2.0.1 to 19.2.0.0 Using DBUA Description:- There are different ways of upgrading to the latest release of Oracle d ...
分类:
数据库 时间:
2020-07-30 10:43:05
阅读次数:
79
1.Lag向上取一条,Lead向下取一条 Lag(Field01) over(order by Field02) 2.Rollup函数即内卷函数 分组统计 3. decode(条件,值1,返回值1,值2,返回值2,...值n,返回值n,缺省值) 4.LAST_DAY(date)表示当月最后一天 5. ...
分类:
数据库 时间:
2020-07-29 00:43:45
阅读次数:
94