摘要:
centos7已经自带python2.7.5,这里需要安装python3 第一步:安装依赖包 yum -y groupinstall "Development tools" yum -y install zlib-devel bzip2-devel openssl-devel ncurses-dev 阅读全文
摘要:
单元格背景色设置 from openpyxl import load_workbook from openpyxl.styles import PatternFill, colors filename = r"E:\Coding\E_PythonWriting\Excel\openpyxl示例_4. 阅读全文
摘要:
使用in运算符 最简单的方法是通过python的 in 运算符。in取两个“参数”,一个在左边,一个在右边,如果左参数包含在右参数中,则返回true。 >>> str = "Messi is the best soccer player" >>> result = "soccer" in str > 阅读全文
摘要:
csv文件转为xlsx import pandas as pd def csv_to_xlsx_pd(): csv = pd.read_csv('1.csv', encoding='utf-8') csv.to_excel('1.xlsx', sheet_name='data') if __name 阅读全文