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
Helen [10]
3 years ago
10

Write a program that receives a filename as user input. The file is structured as multiple lines containing numbers separated by

a single space. For example, this would be an acceptable file:
Computers and Technology
1 answer:
Aliun [14]3 years ago
5 0

Answer:

The solution in Python is as follows:

filename = input("File: ")

fll = open(filename, "r")

for line in fll:

for i in line.split():

 print(i,end='\t')

print()

Explanation:

The complete question implies that the program reads a file and displays the file content in a structured way (tabs or spaces)

The explanation is as follows:

This gets input for the file name

filename = input("File: ")

This opens the file for read operation

fll = open(filename, "r")

This iterates through the lines of the file

for line in fll:

This iterates through each line (splitted by space)

for i in line.split():

This prints the current element followed by a tab

 print(i,end='\t')

This starts printing on another line

print()

You might be interested in
What is the purpose of using SmartArt Graphics and what is one way you can use SmartArt Graphics in your presentation(s)?
Sladkaya [172]
The purpose of smart art graphic is to show is basically for show for people to see and it helps your presentation by giving it a pop to it
7 0
3 years ago
A tool you might use to manipulate an image, such as a photograph, into a seamless repeating texture would be:
nika2105 [10]

I believe the answer is D. I hope I helped :)

7 0
3 years ago
Read 2 more answers
What are the examples of computer software​
jonny [76]

Answer:

Examples of modern applications include office suites, graphics software, databases and database management programs, web browsers, word processors, software development tools, image editors and communication platforms. System software. These software programs are designed to run a computer's application programs and hardware.

Explanation:

Hope this helps :)

Have an amazing day <3

Pls mark brainliest :p

3 0
3 years ago
Read 2 more answers
Which of the following can a cell contain?
vredina [299]
I think it could be All of these.....
5 0
3 years ago
Read 2 more answers
As each layer of the OSI model adds its encapsulation header and/or footer, the ______ gets larger until it reaches the physical
aleksklad [387]

Answer:

Message

Explanation:

  • The Application layer creates a message. The Application layer passes the message to the Presentation layer.
  • The Presentation layer encapsulates the message by adding information to it. Information is usually added only at the beginning of the message (called a header); however, some layers also add material at the end of the message (called a footer)
  • The process of passing the message down and adding layer-specific information continues until the message reaches the Physical layer.
  • At the Physical layer, the message is converted into electrical impulses that represent bits and is transmitted over the physical connection.  
  • The receiving computer captures the bits from the physical connection and re-creates the message in the Physical layer.  
  • The Physical layer converts the message from bits into a Data Link frame and sends the message up to the Data Link layer.
  • The Data Link layer strips its information and sends the message up to the Network layer.
  • This process of deencapsulation is performed until the message reaches the Application layer.
  • When the message reaches the Application layer, the data in the message is sent to the intended software recipient.
5 0
3 years ago
Other questions:
  • You try to enter your name into a cell that accepts a numeric value. What error would you receive
    12·2 answers
  • Your brother is starting 9th grade next year and is thinking about going to college. What step would you recommend he take?
    14·1 answer
  • Consider the following two implementations of the same algorithm, each written in a different language.
    11·1 answer
  • Give two differences between a source and an object program​
    10·1 answer
  • Network Industries, Inc., wants to monitor its employees’ electronic com-munications. To avoid liability under laws related to e
    12·1 answer
  • The pay of an hourly worker is calculated by multiplying the hours worked by the hourly rate—up to 40 hours; any hours worked be
    11·1 answer
  • FOR DIGITAL DESIGN/ PHOTOGRAPHY
    5·2 answers
  • when files on storage are scattered throughout different disks or different parts of a disk, what is it called
    10·1 answer
  • You defined the raft class as shown.
    10·1 answer
  • List three variables that could be used in creating a model that determines the best day to plant corn in a given location. 30 p
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!