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

Describe the scope of the variables in this code.

Computers and Technology
2 answers:
Solnce55 [7]3 years ago
7 0

Answer:

The scope of petName is local to the class pet.

The scope of color is accessible by all parts of the program.

Explanation:

The variable petName is local to the class, because the variable was created in a function whose name begins with two underscores.

The variable color, while created in the petCarrier class, is accessible to the entire function. It was not created in a function whose name begins with an underscore.

Correct answer edge 2020

tensa zangetsu [6.8K]3 years ago
6 0

Answer:

Scope of petName is only limited to class pet (pet class) and scope of color is accessible to the entire program.

Explanation:

petName is restricted by the contructor with an underscore: def __init__(self,strSpecies,strName):, meaning it cannot be manipulated outside that class and color does not have that.

You might be interested in
What makes smartphones so fragile?
In-s [12.5K]
Glass screen probably
7 0
3 years ago
Define get_date() function.
lyudmila [28]

Answer:

I believe it returns the current database system date and time, in a 'YYYY-MM-DD hh:mm:ss.mmm' format.

8 0
3 years ago
When you use the ip address of the web server, the correct site is displayed?
jekas [21]
No. Using the address will get you either the default site, or the first site declared. Web servers can host VirtualHosts, and rely on the site name to know which VirtualHost to serve. TMI, it's called name based virtual host, as opposed to the machine having many addresses then address based virtual hosts can be created.
6 0
3 years ago
Compare and contrast inertial confinement with thermonuclear reactors.
astra-53 [7]
ICF is a type of fusion energy research that attempts to initiate a nuclear fusion reaction by heating and compressing a fuel target. Its normally in the form of a pellet that most often contains a mix of deuterium and tritium.

A nuclear reactor is a device used to initiate and control a sustained nuclear reaction. Nuclear reactors are used at nuclear power plants for electricity generation. 

Compare: they are both nuclear, they both produce energy, they both are used at power plants.

Contrast: ICF uses fusion, while a nuclear reactor is used to control a sustained nuclear reaction. 

This is all I can help with. By the way, are you in rocket science? 'Cause this stuff is hard.
8 0
3 years ago
Please Help!<br><br>in return brainliest and special thanks
arlik [135]
1. Option 3
2. Option 2
3. Option 3
8 0
3 years ago
Other questions:
  • ----------HELP WITH 3 QUESTIONS FOR 30 POINTS!!!---------
    6·1 answer
  • What is indentation?
    8·2 answers
  • Computing devices translate digital to analog information in order to process the information
    8·1 answer
  • Does functionality provided by the app play an important role in a decision to
    13·1 answer
  • Select the correct answer from each drop-down menu. Look at Marta's email signature and fill in the missing elements. Marta D'Ab
    14·2 answers
  • Riya wants to save her project work in an external device so that she can show it to her class teacher. Help her to choose the d
    13·2 answers
  • What factor(s) should be considered when determining whether a business is too far based on the query and the user location? Sel
    10·1 answer
  • 9. Which of the following is the<br>leading use of computer?​
    13·1 answer
  • Give an essay on a way I can be a better person. If not correct I will refund. Best answer gets brainiest. Detailed, 5 sentience
    10·2 answers
  • Active directory and 389 directory server are both compatible with which directory access protocol?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!