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
QveST [7]
3 years ago
8

Write a program that first reads in the name of an input file, followed by two strings representing the lower and upper bounds o

f a search range. The file should be read using the file.readlines() method. The input file contains a list of alphabetical, ten-letter strings, each on a separate line. Your program should output all strings from the list that are within that range (inclusive of the bounds). Ex: If the input is: input1.txt ammoniated millennium and the contents of input1.txt are: aspiration classified federation graduation millennium philosophy quadratics transcript wilderness zoologists the output is: aspiration classified federation graduation millennium
Computers and Technology
1 answer:
xxTIMURxx [149]3 years ago
3 0

Answer:

Python code explained below

Explanation:

f = open(input())

#loading the file, which will serve as the input

s1 = input()  

s2 = input()

lines = f.readlines()

for line in lines:

   line = line.strip(

# strip() removes characters from both left and right

   if s1 <= line <= s2:  #setting the range

       print(line)

f.close()

#closing the file

You might be interested in
Write a recursive function called digit_count() that takes a positive integer as a parameter and returns the number of digits in
Gelneren [198K]

Using the computational knowledge in python it is possible to write a code that Write a recursive function called digit_count()

<h3>What is a function in Python?</h3>

In Python, a function is a sequence of commands that performs some task and that has a name. Its main purpose is to help us organize programs into chunks that correspond to how we envision a solution to the problem.

<h3>Writting the code in python:</h3>

<em>def countDigits(n):</em>

<em>   if n< 10:</em>

<em>      return 1</em>

<em>   else:</em>

<em>       return 1 + countDigits(n / 10)</em>

See more about python at brainly.com/question/13437928

#SPJ1

8 0
2 years ago
While building a high-end gaming system, you are attempting to install the EVGA GeForce GTX 1080 graphics card and discover ther
polet [3.4K]

Answer:

I will use a riser card to install the card parallel to the motherboard.

Explanation:

If you attempted to install a GPU like this and it stands tall, then this means that you do not have enough room for the card. Instead of purchasing a new case that will allow the GPU to seat comfortably, you can buy a riser card. A riser card seats at a right angular position and is built to extend a motherboard slot. I expect a motherboard that supports an EVGA GeForce GTX 1080 graphics card to support a riser card because not all boards support a riser card. Once it is installed, the card will rest on the motherboard and will rotate the GPU to seat parallel with the motherboard.

5 0
3 years ago
0 50 100 150 200 250 300 350 400 Shape Size These shapes are the correct 50 01 100 150 Pattern Reference If you don't have red,
cricket20 [7]

Answer:

0 540 100 200 350 400 550 600 750

Explanation:

hope this helped

4 0
3 years ago
Read 2 more answers
Universal Windows Platform is designed for which Windows 10 version?
Naddika [18.5K]

Universal Windows Platform is an open source API created by Microsoft and first introduced in Windows 10. The purpose of this platform is to help develop universal apps that run on Windows 10, Windows 10 Mobile, Xbox One and HoloLens without the need to be re-written for each. It supports Windows app development using C++, C#, VB.NET, and XAML. The API is implemented in C++, and supported in C++, VB.NET, C#, F# and JavaScript. Designed as an extension to the Windows Runtime platform first introduced in Windows Server 2012 and Windows 8, UWP allows developers to create apps that will potentially run on multiple types of devices.

6 0
3 years ago
Select the correct answer.
9966 [12]

Answer:

B

Explanation:

Every HTML document must begin with a declaration of what the document is going to be about.

4 0
2 years ago
Other questions:
  • business owners and managers may first balk at the idea of mobile officer workers because there may appear to be a lack of ___ w
    9·1 answer
  • 1. Mobile devices have a _________ viewport that displays a web page content that fits within a mobile screen.
    11·1 answer
  • Finding your style in photography is about ___
    10·2 answers
  • .When an argument is passed ______________, the called method can access and modify the caller’s original data directly.
    8·1 answer
  • Write a method named lastFirst that accepts a string as its parameter representing a person's first and last name. The method sh
    13·1 answer
  • •What are some conflicts between humans and machines that have arisen in the past?
    14·1 answer
  • The penalties for a person's third DUI conviction include fines of __________.
    11·2 answers
  • First Person Who Answers Fast As Possible Will Be Marked As Brainiest ​
    12·1 answer
  • In a multiprogramming and time-sharing environment, several users share the system simultaneously. This situation can result in
    9·1 answer
  • which is a correct procedural step for a webpage to render on a user's browser? an information request is sent to an ip address
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!