I have an issue with an open file. First I need to design the name of my file, then it supposed to create a file in a block note with format .txt. Also, I have to use %less in order to print the file.
This is my code:
def file():
name=str(input("write the name of your file: "))
content=str(input("write : "))
with open(name+".txt" , "w") as newfile:
newfile.write(content)
%less name.txt
file()
leer_libro("name.txt") #it counts my letters of each line