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
vagabundo [1.1K]
3 years ago
5

#Write a function called "in_parentheses" that accepts a

Computers and Technology
1 answer:
zimovet [89]3 years ago
8 0

Answer:

import regex as re

def in_parentheses(a_string):

   regeX = re.compile(".*?\((.*?)\)")

   result = re.findall(regeX, a_string)

   return str(result).replace("[","").replace("]","")

print("test 1: "+in_parentheses("Open ( only"))

print("test 2: "+in_parentheses("This is a sentence (words!)."))

You might be interested in
What animal is perry the platypus ​
valkas [14]

Answer: Agent P or simply Perry

Explanation:

4 0
3 years ago
Read 2 more answers
What year did bill gates form traf-o-data?
alexgriva [62]

In 1972 Bill Gates formed Traf-O-Data.

8 0
3 years ago
Given the list of customer segments below please create a new list of the names of the segments only using(a) a for loop(b) a li
Alchen [17]

Answer:

new_segment = [ ]

for segment in segments:

   new_segment.append({'name': segment, 'average_spend': money})

print( new_segment)

Using list comprehension:

new_segment =[{'name': segment, 'average_spend': money}  for segment in segments]

Using map():

def listing(a):

   contain =  {'name': segment, 'average_spend': money}

   return contain

new_segment = [ ]

new_segment.append(map( listing, segment))

print(list(new_segment)

Explanation:

The python codes above create a list of dictionaries in all instances using for loop, for loop in list comprehension and the map function which collect two arguments .

7 0
3 years ago
Use a web browser to find three examples of static webpages and three examples of dynamic webpages, and note the URLs for each p
shepuryov [24]

Answer:

Static web pages are sent as it is at web server without being processed additionally.

Dynamic web pages content may change, and server hosting dynamic web pages return content after processing trough a program.

Examples of dynamic and static web pages are below

Explanation:

<em><u>dynamic websites</u></em>

f o o t y r o o m  (.co) It is a football website. Displays latest highlights and football stats. It is dynamic because it gives live match scores, as the scores change, content change as well.

a c c u w e a t h e r (.com) It shows weather information. It is dynamic because when requested, displays current weather information.

x e (.com)   It is a currency website. Dynamic because it shows live exchange rates.

<em><u>static websites</u></em>

s c i p y - l e c t u r e s (.org) It is a website about scientific python environment. It is static because it gives same content whenever requested.

d o g a c a n d u . b l o g s p o t (.com) it is a blog. Static because the requested content doesn't change unless the blogger adds a new story.  

z t a b l e (.net) It is a website about z-score values and includes z-tables. It is static because its displayed as it is.

5 0
3 years ago
The elements in a string type array will be initialized to ____.?
ivanzaharov [21]
The elements in a string type array will be initialized to "Null".
7 0
3 years ago
Other questions:
  • Hot five was the famous band of which musician?
    14·1 answer
  • What would be a situation in which you could use an excel chart to present your data
    8·2 answers
  • A computer can sort x objects in t seconds, as modeled by the function below:
    5·1 answer
  • Imported data that maintains a refreshable link to its external source is called ____ data.
    7·1 answer
  • Consider the following scenario below and recommend a solution.
    8·1 answer
  • What is the film format that many filmmakers feel is superior to any other format?
    13·1 answer
  • • In your response, please include some examples of the three different types of storage.
    11·2 answers
  • Write code that uses the input string stream inSS to read input data from string userInput, and updates variables userMonth, use
    8·1 answer
  • Not all hardware is connected with wires, some hardware might be connected wirelessly with
    9·1 answer
  • Identify different character components for a given typeface: Arial.
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!