DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
python read file to variable
with open('data.txt', 'r') as file: data = file.read().replace(' ', '')
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#python
#read
#file
#variable
ADD COMMENT
Topic
COMMENT
Name
8+8 =
Submit