在写程序的过程中,经常会遇到各种bug,而python的报错功能其实非常有限,我们仅仅依靠看报错提示,很难找到哪里出了错误!今天就分享一个调试python程序的小技巧: 用input中断程序 用print输出可疑的变量 一:什么情况下可疑调试 学过Matlab的同学应该很容易理解我的意思,Matla ...
分类:
编程语言 时间:
2020-10-31 01:48:57
阅读次数:
20
axios登录前端 1.创建一个Login.vue页面 1.1 写页面 views/Login.vue 在 views/components 下创建 Login.vue 页面 测试axios-{{title}} 1.2 src/router/index.js 中配置vue路由 import Vue ...
分类:
移动开发 时间:
2020-10-30 12:35:17
阅读次数:
65
import time import subprocess sleep_time = 10 while 1: # 用popen设置shell=True不会弹出cmd框 process = subprocess.Popen('adb shell input touchscreen swipe 930 ...
分类:
移动开发 时间:
2020-10-30 11:57:47
阅读次数:
30
1.如何在elementUI的input后面添加单位符号 <i slot="suffix" style="font-style:normal;margin-right: 10px;">℃</i> 2.如何在echarts柱状图上显示数值 在需要显示数值的series里添加: label: { sho ...
分类:
其他好文 时间:
2020-10-30 11:44:30
阅读次数:
23
Jenkins Pipeline 有两种写法: Declare 以及 Script,前一种使用了大量Jenkins基于Groovy实现的DSL,使用起来相对有限制;后一种可以很好的在Jenkinsfile 中是用Groovy语句。 下面记录Script模式下常见的一些注意点: 1. 如何退出当前的b ...
分类:
其他好文 时间:
2020-10-30 11:35:00
阅读次数:
23
配置 slaves [xiaoran@hadoop102 hadoop-2.7.2]$ vim etc/hadoop/slaves 添加(注意:一定不能有多余的空格和空行) hadoop102 hadoop103 hadoop104 同步所有节点配置文件 [xiaoran@hadoop102 had ...
分类:
其他好文 时间:
2020-10-29 10:44:54
阅读次数:
27
1、编写脚本,支持让用户自主选择,使用mysqldump还是xtraback全量备份。 #!/bin/bash. /etc/init.d/functionsusername=rootpassname=123456PS3="Please input a number[1|2]: "mysqldumpd ...
分类:
其他好文 时间:
2020-10-29 10:32:04
阅读次数:
26
说明 array_column ( array $input , mixed $column_key [, mixed $index_key = null ] ) : array array_column() 返回input数组中键值为column_key的列, 如果指定了可选参数index_key ...
分类:
编程语言 时间:
2020-10-29 10:19:33
阅读次数:
25
dom部分: <el-form-item label="上传封面"> <input type="file" id="cover" accept="image/png, image/jpeg, image/jpg" @change="preview(this)"> <span style="displ ...
分类:
其他好文 时间:
2020-10-27 10:58:03
阅读次数:
31
input 01 aaaaaa output 4 input 001 kokokokotlin output 2 #题意: 给定一个划分0代表一个子串,1代表一个子串,问用01子串的方式来表示原串的01组合有多少种,并且01子串不能相同 #思路 可以枚举首部的子串长度,然后用该长度可以计算出相对应的 ...
分类:
其他好文 时间:
2020-10-26 11:20:37
阅读次数:
23