# -*- coding: utf-8 -*-import os#设定文件路径path=r'D:\郭鹏历届真题解析2007-2020'i=1#对目录下的文件进行遍历for file in os.listdir(path):#判断是否是文件 file_name=os.path.join(path,fi ...
分类:
编程语言 时间:
2021-05-24 09:25:18
阅读次数:
0
对近期的数据库配置进行一个记录,方便我以后查阅。 我的Django项目配备的是Mysql的数据库,平时使用的工具是VS Code,推荐安装Mysql插件,效果不错: 下面是在项目的setting.py中配置的Mysql连接数据: DATABASES = { 'default': { 'ENGINE' ...
分类:
数据库 时间:
2021-05-24 09:06:47
阅读次数:
0
写入文件的基本操作 f = open('01.txt',mode='a') f.write("\nhelloworld\n") import time def get_time(): return time.strftime('%Y_%m_%d-%H_%M') # TODO 创建一个文件,文件名为当 ...
分类:
其他好文 时间:
2021-05-24 09:05:40
阅读次数:
0
select concat('drop table ',table_name,';') from information_schema.tables where table_schema='employees' and table_name rlike '^d.*$' into outfile 'd ...
分类:
数据库 时间:
2021-05-24 08:59:21
阅读次数:
0
1.pandas df 与 spark df的相互转换 df_s=spark.createDataFrame(df_p) df_p=df_s.toPandas() 2. Spark与Pandas中DataFrame对比 http://www.lining0806.com/spark%E4%B8%8E ...
分类:
其他好文 时间:
2021-05-24 08:28:14
阅读次数:
0
1.pandas df 与 spark df的相互转换 df_s=spark.createDataFrame(df_p) df_p=df_s.toPandas() 2. Spark与Pandas中DataFrame对比 3.1 利用反射机制推断RDD模式 sc创建RDD 转换成Row元素,列名=值 ...
分类:
其他好文 时间:
2021-05-24 08:26:13
阅读次数:
0
1.C标准的文件读写 可移植性强(跨平台) 1 FILE* pFile = nullptr; 2 const char* pcFilePath = ".//1.text"; 3 4 //文件写 5 errno_t err = fopen_s(&pFile, pcFilePath, "ab"); 6 ...
例子是XE的 只是本人测试的,仅供学习!代码很乱! 在一个程序中测试 IdTcpClient和IdTcpServer有点坑, 测试的时候最好写Client和Server两个程序测试 Unit开始 unit Unit1; interface uses Windows, Messages, SysUti ...
1.精简Linux系统概念模型 1.1 Linux的体系结构 Linux可以分为两部分,分别为用户空间和内核空间,以32位操作系统为例,Linux 默认情况下会将高地址的 1GB 空间分配给内核空间(地址为0xffffffff-0xc0000000),将剩下的3GB空间分配给用户空间。 a) 用户空 ...
分类:
系统相关 时间:
2021-05-24 07:08:34
阅读次数:
0
在做h5上传照片功能时,对照片格式做了以下限制 <input type="file" accept="image/png,image/jpg,image/jpeg" > 但在微信浏览器中,这种写法会无法调用相机,从而直接进入图库 accept="image/*就是正常的 可以把accept="ima ...
分类:
其他好文 时间:
2021-05-24 07:03:49
阅读次数:
0