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
Leno4ka [110]
3 years ago
15

Write a program that reads in a text file, infile.txt, and prints out all the lines in the file to the screen until it encounter

s a line with fewer than 4 characters. Once it finds a short line (one with fewer than 4 characters), the program stops. Your program must use readline() to read one line at a time. For your testing you should create a file named infile.txt. Only upload your Python program, I will create my own infile.txt using break
Computers and Technology
1 answer:
ivanzaharov [21]3 years ago
8 0

Answer:

Explanation:

f=open("infile.txt","r")

flag=True

while(flag):

s=f.readline().strip()

if(len(s)>=4):

print(s)

else:

flag=False

You might be interested in
Which security procedure is being demonstrated if an administrator is using Wireshark to watch for specific inbound and outbound
defon

Answer:

The correct answer to the following question will be Option C (Firewall monitoring).

Explanation:

Firewall monitoring would be the analysis of essential firewall parameters that play a key role throughout the effective operation of firewalls.

Usually, management of the firewalls should include:

  • Monitoring the firewall file.
  • Management of the firewall statute.
  • Monitoring the design of the firewall.

Firewall security control is shown if the user uses Wire-shark to track relevant incoming and outgoing traffic.

Therefore, Option C is the right answer.

4 0
3 years ago
Some people argue that developers should not be involved in testing their own code but all testing should be the responsibility
GalinKa [24]

Answer:

People code in their own styles which can make it hard for other people to understand it, especially if it doesn't have any documentation, but that could be a reason to let a separate team test it, so the developer can learn how to code in a way that is understood by most people.

Explanation:

7 0
3 years ago
Using technologies increase the time needed to complete a task is beneficial
nata0808 [166]

Answer:

True

Explanation:

The advent of technology has given human to achieve a whole lot more in a rather short period of time when compared to the period where the major tool of engagement and task is Manual. With technology, aside from having the ability to complete task faster, we can achieve more accurate result and a lot attractive output. All these in very little time. Technology has helped industries grow multiple times faster thus increasing input, yield and productivity. The tedious nature of having to work manually has also been expunged with repetitive task now being programmed and automated.

3 0
3 years ago
The Internet can both reduce and increase the bargaining power of suppliers, depending on the specific circumstances.
slamgirl [31]

Answer:

True                                                                                

Explanation:

Internet can reduce bargaining power of suppliers:

Internet is a powerful means which has strengthen competitiveness in organizations. This has led to competition which results in price wars. This decreases the bargaining power of suppliers as the competition among different suppliers intensifies and the need of the buyers to buy only from a few suppliers is lessened. This also results in the increased bargaining power of buyers. Internet enables buyers to save their time and money and has increased transparency e.g. services costs which resulted in increase bargaining power of buyers while reducing the bargaining power of suppliers. This transparency increased price competition and competitiveness . Consequently buyers are less loyal to certain suppliers and can choose the suppliers who meet their requisites.

Internet can increase bargaining power of suppliers:

Through internet the bargaining power of suppliers can be increased. The internet has given a cost effective platform to suppliers to reach to their customers which has increased competition between suppliers. Suppliers can access more customers and provides better services to them. With internet connectivity suppliers can directly communicate with their customers. The internet can increase the bargaining power of suppliers by allowing reduction of entry barriers and increasing number of competitors.

7 0
4 years ago
PLEASE HELP
dimulka [17.4K]
It’s C, balanced forces.
8 0
3 years ago
Other questions:
  • A school librarian has been asked to identify inappropriate Internet usage. Which students would most likely be reported to the
    5·2 answers
  • You have a hard disk that is formatted with the fat32 file system. you would like to implement file and folder permissions on th
    10·1 answer
  • PowerPoint Presentation on What type of device will she use to display her presentation and explain it to the rest of the childr
    13·2 answers
  • Write the definition of a function named printstarbucks that receives a non-negative integer n and prints a line consisting of n
    6·1 answer
  • The two fundamental approaches to moving data through a network of links and switches are
    9·1 answer
  • You are a developer for a company that is planning on using the AWS RDS service. Your Database administrator spins up a new MySQ
    7·1 answer
  • What is the output of this program ? Assume the user enters 3,6 and 11​
    5·1 answer
  • Which of the following is an object such as a field which can be inserted into a document
    7·1 answer
  • Explain four sitting postures in a computer laboratory​
    9·1 answer
  • See attached. I have code typed out but still having problems.
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!