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
daser333 [38]
3 years ago
5

Use python

Computers and Technology
1 answer:
konstantin123 [22]3 years ago
6 0

Answer:

Here is the Python program:

def exec_2(f):

    f()

    f()

   

def exec_4(f):

    exec_2(f)

    exec_2(f)

   

def print_koala():

    print("koala")    

exec_4(print_koala)

Explanation:

The program works as follows:

First method:

def exec_2(f):

f()

f()

any function that is passed into exec_2() will be executed twice without parameters.

Second method:

def exec_4(f):

    exec_2(f)

    exec_2(f)

function exec_4(f) takes in a function f as a parameter and executes the function f 4 times using the function exec_2. At first exec_2(f) call the function f is executed twice and and second exec_2(f) call the function f is again executed twice so the function f executes 4 times in total.

Third method:

def print_koala():

    print("koala")  

a function that prints out the koala once

This function has a print statement which is passed the string koala to print on output screen.

exec_4(print_koala)

function exec_4 is used to print koala four times. This function exec_4 takes as argument the function print_koala() So this works as follows:

exec_4(print_koala)

The body of exec_4 executes as:

exec_2(print_koala)

exec_2(print_koala)

Now at first call to exec_2(print_koala) the program moves to the function exec_2 which executes print_koala()  method twice. Since print_koala() method has a print statement print("koala") so this is executed twice:

koala                                                                                                                                           koala

Now at second call exec_2(print_koala) the program moves to the function exec_2 which executes print_koala()  method twice again. Since print_koala() method has a print statement print("koala") so this is executed again twice:

koala                                                                                                                                           koala

So the output of the entire above program is:

koala                                                                                                                                           koala                                                                                                                                           koala                                                                                                                                           koala

The screenshot of program along with its output is attached.

You might be interested in
Joe a frequent visitor to a branch office attempts to connect his tablet to the office wireless network but is unable to connect
suter [353]

Answer:

Airplane mode has been set on the tablet.

Explanation:

Joe a frequent visitor to a branch office attempts to connect his tablet to the office wireless network but is unable to connect to the internet even though he has verified that the SSID and password are correct. Joe attempts to connect to a coworker's hotspot but is still unable to connect to the internet.

This is because the Airplane mode has been set on the tablet.

5 0
3 years ago
_____ CRM systems are hosted by an external vendor in the vendor's data center.
PtichkaEL [24]

Answer: On- demand

Explanation:

 On demand CRM system are basically hosted by the external vendor in the vendor data center. CRM is basically stand for customer relationship management.

CRM is a strategy that are used for managing the organisation relationship with the customers.

On demand CRM define as software availability for the customers. It basically connected with the idea of software on demand. The software are modify according to the current requirement and demand.

8 0
3 years ago
Scenario: 1. Victim opens the attacker's web site. 2. Attacker sets up a web site which contains interesting and attractive cont
Ann [662]

Answer :

These sort of attacks are known are Injected IFrame Attacks. The Injected IFrame Attacks are a common Cross Site Scripting or XCC attack that contains multiple or single iFrame tags implemented within a page which is not visible to user. User unintentionally enters his information which is posted to hacker’s server and information’s gets hacked.

5 0
3 years ago
"Bullet Lists" can be which of the following?
MariettaO [177]

Answer:

letters and numbered

Explanation:

7 0
3 years ago
Read 2 more answers
Who still plays old Nintendo 64 games?
Lesechka [4]

Answer:

I play Nintendo 64 games when I was young. I use to love playing Mario 64 as well.

8 0
2 years ago
Read 2 more answers
Other questions:
  • Encryption relies on the use of _________to ensure that information is readable only by the intended recipient.
    5·1 answer
  • Desktop, laptop, and tablet computers, and mobile devices are classified as _______.
    7·1 answer
  • Using social media and sending a blast are examples of
    13·1 answer
  • The transitions between slides in a presentation are one type of powerpoint ____.
    6·1 answer
  • What is another name for a central processing unit? Computer Integrated circuit Microprocessor Transistor
    9·2 answers
  • Name similarities between innovation and invention
    6·1 answer
  • What connectors are available for components to be connected externally to the motherboard
    12·2 answers
  • The Fibonacci sequence begins with 0 and then 1 follows. All subsequent values are the sumof the previous two, for example: 0, 1
    11·1 answer
  • What is the code for this please?​
    13·1 answer
  • How do you stop getting emails from brainly saying "sarah from brainly has answered your question"
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!