1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
mestny [16]
3 years ago
7

Write a program that will open a file named thisFile.txt and write every other line into the file thatFile.txt. Assume the input

file (thisFile.txt) resides in the same directory as your code file, and that your output file (thatFile.txt) will reside in the same location. Do not attempt to read from or write to other locations.
Computers and Technology
1 answer:
Naily [24]3 years ago
4 0

Answer:

Check the explanation

Explanation:

The programmable code to solve the question above will be written in a python programming language <u><em>(which is a high-level, interpreted, general-purpose programming language.)</em></u>

<u><em /></u>

f = open('thisFile.txt', 'r')

w = open('thatFile.txt', 'w')

count = 0

for line in f:

   if count % 2 == 0:

       w.write(line)

   count += 1

w.close()

f.close()

You might be interested in
How much does it cost to go to csun school
wolverine [178]
I believe you will find all your answers here,

http://www.csun.edu/prospectivestudents/cost-attendance
6 0
3 years ago
Hannah is editing her brother’s birthday video. She has selected the usable shots and copied them onto her computer. What is the
Y_Kistochka [10]

Answer:

She needs to create the final music

3 0
2 years ago
FREEEEEEEEEEEEE FREEEEEEEEEEEEE Pointttssss​
Paul [167]

Answer:

Thx TYSM TYSM

Explanation:

8 0
3 years ago
Read 2 more answers
What two sets of data does every folder and file on an ntfs partition list?
QveST [7]
Read and execute are the two sets of data
8 0
3 years ago
Which of the following is not a responsibility of an operating system?
FromTheMoon [43]
The answer would be “automatically upgrade the computer’s RAM”. RAM is a computer part that would need to be bought and placed in the computer by the user.
5 0
3 years ago
Read 2 more answers
Other questions:
  • Which relationship is possible when two tables share the same primary key?
    9·2 answers
  • Which function is used to display a string value to the screen?
    8·1 answer
  • What does a contain after the following code runs?int[] a = {1, 3, 7, 0, 0, 0};int size = 3, capacity = 6, value = 5;int pos = 0
    10·1 answer
  • Question 1 :The most common business firewall technique is to use a firewall server in conjunction with:This task contains the r
    11·1 answer
  • Provide the definition for each of the following structures and unions:
    8·1 answer
  • How to study program ?
    11·1 answer
  • You are installing a single 802.11g wireless network. The office space is large enough that you need three WAPs. What channels s
    10·1 answer
  • Brainly is brainly am I correct ​
    11·2 answers
  • Can some one please help
    9·1 answer
  • One of the difficult things about working in game design is that while there are many different roles, most of them only match o
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!