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
GalinKa [24]
3 years ago
6

According to programming best practices, how should you handle code that needs to be repeated several times in a program?

Computers and Technology
1 answer:
ahrayia [7]3 years ago
8 0

Explanation:

Copy the code as many times as needed so that each usage is separate.

You might be interested in
How do you implement instruction level parallelism
netineya [11]

Answer:

To obtain substantial performance enhancements, we must exploit ILP across multiple basic blocks.

Explanation:

8 0
3 years ago
Edhesive unit 4 test
sergij07 [2.7K]

Answer:

padna jana ta yarrr kasto this yarr

8 0
3 years ago
Create a base class named rectangle that contains lenght and width data members.
kumpel [21]

Answer:

class Rectangle:  

   

   def __init__(self, length, width):

       self.length = length

       self.width = width

       

   

   def area(self):

       area = self.length*self.width

       return area

   

   

class Box (Rectangle):

   

   def __init__(self, length, width, height):

       super().__init__(length, width)

       self.height = height

       

   def volume(self):

       volume = self.length * self.width * self.height

       return volume

   

   def area(self):

       area = 2*(self.length*self.width) + 2*(self.length*self.height) + 2*(self.width*self.height)

       return area

rec_1 = Rectangle(2,4)

box_1 = Box(2,2,6)

print(box_1.length)

print(box_1.area())

   

print(rec_1.length)

print(rec_1.area())

Explanation:

The programming language used is python.

class Rectangle

The class Rectangle is created with attributes length and width.

The class attributes are initialized using the __init__ constructor.

In the rectangle class, a method/function is declared to return the area of the rectangle.

class Box

This class is a child of rectangle and it inherits all its attributes and methods,

It has an additional attribute of depth and its constructor is used to initialize it.

The class contains a volume function, that returns the volume and an override function 'area()' that displaces the area from the parent class.

Finally, some instances of both classes are created.

4 0
3 years ago
Which type of link is normally used to interconnect two peripheral modules (pm) in the digital multiplex system (dms)?
natta225 [31]

The answer is DS-30A. The Roland DS30A is a 24-bit Digital Reference Monitor which can add pristine 24-bit/96kHz. They are small speakers.

4 0
3 years ago
Which of the following is NOT an advantage of owning a car?
AnnyKZ [126]

Smaller down and monthly payments than leasing a car

Option A.

<u>Explanation:</u>

If you lease a car, then the amount of money that a person has to pay in the form of monthly payments and installments is less when compared to when a person owns a car.

When you own a car, the monthly payment made is more than the monthly payments compared to when the car has to be leased. This is the disadvantage of owning a car, that the payment is more to be made.

8 0
3 years ago
Other questions:
  • A binary search can be performed only on ____.
    6·1 answer
  • For an alternative to the String class, and so that you can change a String's contents, you can use_________ .
    12·1 answer
  • HELP QUICKLY!!! IF YOUR RIGHT I'LL MARK YOU BRAINLIEST
    15·2 answers
  • From your fist impression, write down what first comes to mind as to what is good and bad about the way the device works.
    14·1 answer
  • Briefly describe the traditional definition of the digital divide. What is it and who is affected, positively and adversely? How
    15·1 answer
  • Which of the following symbols is a part of all spreadsheet functions?
    7·2 answers
  • True or false a mirrorless camera has a pentaprism
    14·2 answers
  • Describe four traditional tehniques for collecting information during analysis.
    11·1 answer
  • Most file managers include a way to create a folder through the save dialog box. true or false?
    9·1 answer
  • You have installed a new sound card in your system, closed the computer case, and turned on the computer. Windows boots and you
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!