当前位置:网站首页>Write the list to txt and directly remove the comma in the middle
Write the list to txt and directly remove the comma in the middle
2022-07-24 06:02:00 【Julyers】
import os
wd = os.getcwd() # Get the current directory
list = ['800', '600', '0', '204', '294', '389', '450', '320', '349', '446', '482', '480', '382', '110', '376', '145', '272', '410', '387', '428', '333', '234', '330', '252', '275']
save_path = '/home/juling/Jupyter Project/test_folder'
txt = open(os.path.join(save_path, 'test.txt'), 'w')
txt.write(wd + ' ' + ' '.join(str(i) for i in list))
txt.close()
effect :
边栏推荐
猜你喜欢

C language linked list (create, traverse, release, find, delete, insert a node, sort, reverse order)

Typora installation package in November 2021, the last free version of the installation package to download v13.6.1

"Statistical learning methods (2nd Edition)" Li Hang Chapter 16 principal component analysis PCA mind map notes and after-school exercise answers (detailed steps) PCA matrix singular value Chapter 16

LSTM神经网络

How to solve the problem of large distribution gap between training set and test set

"Statistical learning methods (2nd Edition)" Li Hang Chapter 17 latent semantic analysis LSA LSI mind mapping notes and after-school exercise answers (detailed steps) Chapter 17

JUC并发编程基础(9)--线程池

STM32 DSP库MDK VC5\VC6编译错误: 256, (const float64_t *)twiddleCoefF64_256, armBitRevIndexTableF64_256,

jestson安装ibus输入法

用指针访问二维数组
随机推荐
读取csv文件的满足条件的行并写入另一个csv中
信号与系统:希尔伯特变换
Vscode multiline comments always expand automatically
[MYCAT] related concepts of MYCAT
Qt新建工程简介
C语言链表(创建、遍历、释放、查找、删除、插入一个节点、排序,逆序)
day-7 jvm完结
JS star scoring effect
Qt新手入门级 计算器加、减、乘、除、应用
How to solve the problem of large distribution gap between training set and test set
JUC并发编程基础(1)--相关基础概念
Qt 使用纯代码画图异常
day2-WebSocket+排序
Machine learning (zhouzhihua) Chapter 5 notes on neural network learning
tensorflow和pytorch框架的安装以及cuda踩坑记录
绘制轮廓 cv2.findContours函数及参数解释
列表写入txt直接去除中间的逗号
KMP代码分布详解
vsual studio 2013环境 Udp组播
[activiti] group task