BOTH QUESTIONS ONLY FILL IN C++ CODEWrite a copy constructor for CarCounter that assigns origCarCounter.carCount to the constructed object's carCount. Sample output for the given program:Cars counted: 5Sample program:#include using namespace std;class CarCounter { public: CarCounter(); CarCounter(const CarCounter& origCarCounter); void SetCarCount(const int count) { carCount = count; } int GetCarCount() const { return carCount; } private: int carCount;};CarCounter::CarCounter() { carCount = 0; return;}// FIXME add copy constructorvoid CountPrinter(CarCounter carCntr) { cout << "Cars counted: " << carCntr.GetCarCount(); return;}int main() { CarCounter parkingLot; parkingLot.SetCarCount(5); CountPrinter(parkingLot); return 0;}QUESTION #2!!!!!!!!!!!!!!!!_______________----------------------------------------------_______________________________Overload the + operator as indicated. Sample output for the given program:First vacation: Days: 7, People: 3Second vacation: Days: 12, People: 3Sample program:#include using namespace std;class FamilyVacation{ public: void SetNumDays(int dayCount); void SetNumPeople(int peopleCount); void Print() const; FamilyVacation operator+(int moreDays) const; private: int numDays; int numPeople;};void FamilyVacation::SetNumDays(int dayCount) { numDays = dayCount; return;}void FamilyVacation::SetNumPeople(int peopleCount) { numPeople = peopleCount; return;}// FIXME: Overload + operator so can write newVacation = oldVacation + 5,// which adds 5 to numDays, while just copying numPeople. void FamilyVacation::Print() const { cout << "Days: " << numDays << ", People: " << numPeople << endl; return;}int main() { FamilyVacation firstVacation; FamilyVacation secondVacation; cout << "First vacation: "; firstVacation.SetNumDays(7); firstVacation.SetNumPeople(3); firstVacation.Print(); cout << "Second vacation: "; secondVacation = firstVacation + 5; secondVacation.Print(); return 0;}

Answers

Answer 1

Answer:

im lost tell me a question then ill answer

Explanation:


Related Questions

Comment on the following 2 arrays. int *a1[8]; int *(a2[8]); a1 is pointer to an array; a2 is array of pointers a1 is pointer to an array; a2 is pointer to an array a1 is array of pointers; a2 is pointer to an array a1 is array of pointers; a2 is array of pointers

Answers

Answer:

The answer is "a1 and a2 is an array of pointers".

Explanation:

In this question, A collection of pointers refers to an array of elements where each pointer array element points to a data array element. In the above-given statement, the two-pointer type array "a1 and a2" is declared that holds the same size "8" elements in the array, and each element points towards the array's first element of the array, therefore, both a1 and a2 are pointer arrays.

) Printers today have many features that include improved quality, photo printing capabilities, digital camera connectivity, built-in flash memory card readers, wireless connectivity, and faster speed. Suppose you are in the market for a new personal printer. Make a list of the most important features needed to meet your needs, and then research printers to identify the best printer for your needs. Be sure to consider both the price of the printer and the price of consumables (such as paper and ink/toner) in your evaluation process. (3 marks)

Answers

Explanation:

Some of the most important features needed in a printer are:

fast printing speedsupport wireless connectivitysupport colored/uncolored printinginclude improved text quality,improved photo printing capabilities

Based on market prices available on the Amazon website, a printer with the above capabilities start at a price range of at least $80.

(Decimal to binary) Write a recursive method that converts a decimal number into a binary number as a string. The method header is public static String dec2Bin(int value) Write a test program that prompts the user to enter a decimal number and displays its binary equivalent.

Answers

Answer and Explanation:

import java.util.Scanner;

public class convertToBinary {

public static String declToBin(int value){

if(value == 1){

return declToBin((value/2) + "" + (value%2);

}

else{

declToBin((value/2) + "" + (value%2);

}

}

public static void main(String args[]){

int number;

Scanner change = new Scanner(System.in);

System.out.print("Enter decimal value: ");

number = change.nextInt();

System.out.println(declToBin(number));

}

}

The recursive function declToBin(int value) keeps executing code until value==1. Recursive functions reduces lines of code and makes it more efficient.

Note: Decimal is number in base 10(denary). To convert a decimal number to base 2(binary), we keep dividing the decimal number entered by the user by 2 until the result is zero(when the number divided is one)

We use the Java programming language here. First we import the Scanner object(import.java.util.Scanner). We use the method nextint() from the object to convert the string value entered by the user to int value( because our declToBin function takes an int parameter).

In a three-tier architecture, the component that runs the program code and enforces the business processes is the:_______.

Answers

Answer:

Application Server

Explanation:

The Application Server is a component in computer engineering that presents the application logic layer in a three-tier architecture.

This functionality allows client components to connect with data resources and legacy applications.

In this process of interaction, the Application Server runs the program code from Tier 1 - Presentation, through Tier 2 - Business Logic to Tier 3 - Resources, by forcing through the business processes.

Read the following statements and select the
conditional statements. Check all that apply.
If my car starts, I can drive to work
It is inconvenient when the car does not start.
If my car does not start, I will ride the bus to
work
I purchased this car used, and it is not
reliable

Answers

if my car starts, i can drive to work

if my car does not start, i will ride the bus to work

Answer:

if my car does not start, i will ride the bus to work

if my car starts, i can drive to work

Explanation:

90 points can someone please write the code for this (HTML):


A text field to enter your name.

At least three multiple choice questions where only one answer can be chosen.

A word problem with a text area for the user to type in the answer.

At least three different math symbols using correct ampersand notation.

A Submit button at the end of the test.

Comment tags that indicate the start and end of the test.


I need to get this done really soon, please help. I couldn't find any text to HTML sites that included multiple choice and Interactive buttons.

Answers

Answer:

Explanation:

1.

First name:

Last name:

.

2.

What fraction of a day is 6 hours?

Choose 1 answer

6/24

6

1/3

1/6

Submit

</p><p> // The function evaluates the answer and displays result</p><p> function displayAnswer1() {</p><p> if (document.getElementById('option-11').checked) {</p><p> document.getElementById('block-11').style.border = '3px solid limegreen'</p><p> document.getElementById('result-11').style.color = 'limegreen'</p><p> document.getElementById('result-11').innerHTML = 'Correct!'</p><p> }</p><p> if (document.getElementById('option-12').checked) {</p><p> document.getElementById('block-12').style.border = '3px solid red'</p><p> document.getElementById('result-12').style.color = 'red'</p><p> document.getElementById('result-12').innerHTML = 'Incorrect!'</p><p> showCorrectAnswer1()</p><p> }</p><p> if (document.getElementById('option-13').checked) {</p><p> document.getElementById('block-13').style.border = '3px solid red'</p><p> document.getElementById('result-13').style.color = 'red'</p><p> document.getElementById('result-13').innerHTML = 'Incorrect!'</p><p> showCorrectAnswer1()</p><p> }</p><p> if (document.getElementById('option-14').checked) {</p><p> document.getElementById('block-14').style.border = '3px solid red'</p><p> document.getElementById('result-14').style.color = 'red'</p><p> document.getElementById('result-14').innerHTML = 'Incorrect!'</p><p> showCorrectAnswer1()</p><p> }</p><p> }</p><p> // the functon displays the link to the correct answer</p><p> function showCorrectAnswer1() {</p><p> let showAnswer1 = document.createElement('p')</p><p> showAnswer1.innerHTML = 'Show Corrent Answer'</p><p> showAnswer1.style.position = 'relative'</p><p> showAnswer1.style.top = '-180px'</p><p> showAnswer1.style.fontSize = '1.75rem'</p><p> document.getElementById('showanswer1').appendChild(showAnswer1)</p><p> showAnswer1.addEventListener('click', () => {</p><p> document.getElementById('block-11').style.border = '3px solid limegreen'</p><p> document.getElementById('result-11').style.color = 'limegreen'</p><p> document.getElementById('result-11').innerHTML = 'Correct!'</p><p> document.getElementById('showanswer1').removeChild(showAnswer1)</p><p> })</p><p> }</p><p>

3.<p> rows="5" cols="30"</p><p> placeholder="type text.">

4. <p>I will display &euro;</p>

<p>I will display &part;</p>

<p>I will display &exist;</p>

5. <input type="submit">

6. This code should be the first code

<!-- This is a comment -->

<p>Start Test.</p>

<!-- Remember to add more information here -->

This code should be the last and at the end of the of the html code

<!-- This is a comment -->

<p>End Test.</p>

<!-- Remember to add more information here -->

Notice: Answers may not be accurate and may be accurate. And pls endeavor to edit any part of the html code.

Write a loop that subtracts 1 from each element in lowerScores. If the element was already 0 or negative, assign 0 to the element. Ex: lowerScores = {5, 0, 2, -3} becomes {4, 0, 1, 0}.Sample program:#include using namespace std;int main() { const int SCORES_SIZE = 4; vector lowerScores(SCORES_SIZE); int i = 0; lowerScores.at(0) = 5; lowerScores.at(1) = 0; lowerScores.at(2) = 2; lowerScores.at(3) = -3; for (i = 0; i < SCORES_SIZE; ++i) { cout << lowerScores.at(i) << " "; } cout << endl; return 0;}Below, do not type an entire program. Only type the portion indicated by the above instructions (and if a sample program is shown above, only type the portion.)

Answers

Answer:

Replace <STUDENT CODE> with

for (i = 0; i < SCORES_SIZE; ++i) {

       if(lowerScores.at(i)<=0){

           lowerScores.at(i) = 0;

       }

       else{

           lowerScores.at(i) = lowerScores.at(i) - 1;

       }  

   }

Explanation:

To do this, we simply iterate through the vector.

For each item in the vector, we run a check if it is less than 1 (i.e. 0 or negative).

If yes, the vector item is set to 0

If otherwise, 1 is subtracted from that vector item

This line iterates through the vector

for (i = 0; i < SCORES_SIZE; ++i) {

This checks if vector item is less than 1

       if(lowerScores.at(i)<1){

If yes, the vector item is set to 0

           lowerScores.at(i) = 0;

       }

       else{

If otherwise, 1 is subtracted from the vector item

           lowerScores.at(i) = lowerScores.at(i) - 1;

       }  

   }

Also, include the following at the beginning of the program:

#include <vector>

Given a type Money that is a structured type with two int fields, dollars and cents. Assume that an array named monthlySales with 12 elements, each of type Money has been declared and initialized. Assume that a Money variable yearlySales has also been declared. Write the necessary code that traverses the monthlySales array and adds it all up and stores the resulting total in yearlySales. Be sure make sure that yearlySales ends up with a valid value, i.e. a value of cents that is less than 100.

Answers

Answer:

Attached below is the code

Explanation:

using namespace std;

struct Money

{

int dollars;

int cents;

};

int main()

{

struct Money monthlySales[12];

struct Money yearlySales = { 0,0};

for(inti=0; i<12; i++)

{

monthlySales[i].dollars = 0.0;

monthlySales[i].cents = 0.0;

}

for(int i=0; i<12; i++)

{

yearlySales.dollars = yearlySales.dollars + monthlySales[i].dollars;

yearlySales.cents = yearlySales.cents +monthlySales[i].cents;

}

return 0;

}

The long-run average cost curve is typically _______________________. a) downward-sloping at first but then b) upward-sloping upward-sloping at first but then c) downward-sloping always d) downward-sloping always upward-sloping

Answers

Answer:

A. downward-sloping at first but then upward-sloping

Explanation:

The long-run average cost curve is typical "downward-sloping at first but then upward-sloping." This can be shown as the long-run average cost curve is graphically represented in a U shape.

The reason is that the long-run average cost of production initially falls as a result of increase returns to scale as output is increased, however, at some stage beyond this certain this, the long-run average cost of production rises because of decreasing returns of scale.

Write a program to output the following quote by Edsger W. Dijkstra:

"Computer Science is no more about computers
than astronomy is about telescopes"
- Edsger W. Dijkstra
Hint: Remember that the escape characters \n and \" can be used to create new lines and quotation marks in your code.

Answers

In python 3.8:

print("\"Computer Science is no more about \ncomputers\nthan astronomy is about telescopes\"\n-Edsger W. Dijkstra")

I hope this helps!


What is a file type and why is it important? Give at least three examples of file
types, including the associated file extension and
program.

Answers

What's in the setting file ?

Write a program that asks the user to input their first and last names. The first prompt should state:

Please input your first name:
The second prompt should state:

Please input your last name:
After accepting the inputs, your program should output the input in the form last name, first name.

Hint: Remember that you can concatenate (add) two phrases by using the + symbol. Don't forget that you'll need to add a comma as well and that the comma must be followed by a space.

Answers

first = input("Please input your first name: ")

last = input("Please input your last name: ")

print(last+", "+first)

I hope this helps!

what are the types of slide show in powerpoint? define.​

Answers

Answer:

normal view

slide sorter view

master view

notes page view

What is the name of the setting that creates a Green Dashed line and allows you to set angular locks when activation

Answers

Answer:

Polar Tracking

Explanation:

Polar Tracking a term or function in AUTOCAD that is used to identify a point closest to a predetermined angle and define a distance along that angle. This helps creates a line (which is a green dashed line). Thereby enabling a user to set angular locks when or during activation.

Hence, in this case, the correct answer to the question is POLAR TRACKING

A computer is using a fully associative cache and has 216 bytes of memory and a cache of 64 blocks, where each block contains 32 bytes.

Required:
a. How many blocks of main memory are there?
b. What is the format of a memory address as seen by the cache, that is, what are the sizes of the tag and offset fields?
c. To which cache block will the memory address F8C9 (subscript) 16 map?

Answers

1) The number of blocks of main memory that are there are;

2^16/32 = 2^16/2^5 = 2^11

2) The format of a memory address as seen by the cache,that is the sizes of the tag and offset fields are;

16 bit addresses with 11 bits also in the tag field and the 5 bits in the word field.

3) The cache block that the memory address F8C9 (subscript) 16 map;

Since it is an associative cache, it can actually map anywhere.

That is, it has the ability of mapping anywhere.

An anagram of a string is another string with the same characters in the same frequency, in any order. For example 'ab', 'bca, acb), 'bac', 'cba, 'cab' are all anagrams of the string 'abc'. Given two arrays of strings, for every string in one list, determine how many anagrams of it are in the other list. Write a function that receives dictionary and query, two string arrays. It should return an array of integers where each element i contains the number of anagrams of queryll that exist in dictionary.

Answers

Answer:

from collections import Counter

def anagram(dictionary, query):

   newList =[]

   for element in dictionary:          

       for item in query:

           word = 0

           count = 0

           for i in [x for x in item]:

               if i in element:

                   count += 1

                   if count == len(item):

                       newList.append(item)

   ans = list()

   for point in Counter(newList).items():

       ans.append(point)

   print(ans)        

mylist = ['jack', 'run', 'contain', 'reserve','hack','mack', 'cantoneese', 'nurse']

setter = ['ack', 'nur', 'can', 'con', 'reeve', 'serve']

anagram(mylist, setter)

Explanation:

The Counter class is used to create a dictionary that counts the number of anagrams in the created list 'newList' and then the counter is looped through to append the items (tuple of key and value pairs) to the 'ans' list which is printed as output.

what will be output of this program a. less than 10 b. less than 20 c. less than 30 d. 30 or more

Answers

Answer:

D. 30 or more

Explanation:

The score value is passed in as var, meaning, its value could change. In this instance score started at zero and 30 was added to it. The last condition is the only condition that fits score's value(if that makes sense). So its in fact D.

hope i was able to help ;)

Write a code for function main, that does the following: creates a variable and assign it the value True. uses a while loop which runs as long as the variable of the previous step is True, inside the while loop, get three integer numbers n1, n2 and n3 from the user and

Answers

Answer:

def main():

   is_true = True

   while is_true == False:

       try:

           num1 = int(input("Enter first number: ")

           num2 = int(input("Enter second number: ")

           num3 = int(input("Enter third number: ")

       except ValueError:

           print("Input must be an integer number")

       is_true = bool(input("do you want to end loop? True/False: "))

main()

Explanation:

The python main function above continuously creates three integer numbers in a while loop statement until a false input is received from the user.

What symbol following a menu command lets you know that a dialog box will be displayed? an ellipse an arrow a check mark a radio button

Answers

cords   and  batteries or electric radio

Answer:

It would be an ellipse

What best describes "broadband access"?
a. broadband access is a specific term used to describe the delivery of one-way television programming to subscribers.
b. broadband access describes any digital network that supports 1 Gbps or greater bit rates.
c. broadband access is a term only applicable to analog television programming.
d. broadband access describes technical methods that enable users to connect to high speed networks.

Answers

Answer:

The Correct option is : d. BROADBAND ACCESS enable users to connect to a high speed networks

Explanation:

As the names implies BROADBAND ACCESS can be defined as a technology that enables users to have the access to fast and high speed internet connection when browsing, streaming or downloading reason been that BROADBAND ACCESS is more faster and quicker which inturn enables the user to do a lot more on the internet which is why BROADBAND ACCESS is often refer or known as a high and fast speed Internet access connection.

what is suitable equipment to meet customer needs from
1 stand alone pcs
2 networked pcs
3 servers
4 network equipment
5 operating system
6 application software

Answers

uh i think it’s uh carrot

What does cpu mean ​

Answers

Answer:

CPU or Central processing unit is the principal part of any digital computer system, generally composed of the main memory, control unit, and arithmetic-logic unit.

Hope this helps and if you could mark this as brainliest. Thanks!

Need help with 4.7 lesson practice

Answers

Answer: Question 1 is A  Question 2 is C

Explanation:

_______________ is a computer networking protocol used by hosts to retrieve IP address assignments.

Answers

Answer:

DHCP

Explanation:

stands for dynamic host configuration protocol and is a network protocol used on IP networks where a DHCP server automatically assigns an IP address and other information to each host on the network so they can communicate efficiently with other endpoints.

(plsssssssssssssssssssssssssssssssssssssss helpp meee)
think about system you know,list the parts of the system,describe some ways that the parts are connected to the whole​

Answers

Answer:

A computer is a complex machine. While most of it works on a microscopic level, it certainly has recognizable macroscopic components that contribute to its uses. A computer can be used to do just about anything from simple calculations to preparing reports to sending rockets into space to simulating the spread of cancer in body organs. Some of the parts are, the motherboard, the power supply, the central processing unit, the optical drive ect. The motherboard plays roles like storing some simple information when the computer is off, such as the system time. The power supply, as you might have already guessed is the powerhouse of the computer. The CPU mainly does arithmetic and logical tasks. It will make a bunch of calculations to ensure the functions of the computer are carried out efficiently. An optical drive is used to read CDs and DVDs, which can be used to listen to music or watch movies. They can also be used to install software, play games, or write new information into a disk.

Explanation: O///O sorry if this is bad....

Claire wants to be a digital media coordinator. What requirements does she need to fulfill in order to pursue this career?

To be a digital media coordinator, Claire needs a bachelor’s degree in _______ digital media, or a related field. She also needs to have knowledge of _______ and emerging digital technologies.

1st blank:
psychology
public relations
finance

2nd blank:
computer programming
computer coding
search engine optimization

Answers

Answer:

1. Public Relations

2. Search Engine Optimization

Explanation:

Given that a public relations degree holder can work in various capacities such as Advertising, Media, Event, and Sale promotion position. Hence Claire needs a bachelor’s degree in PUBLIC RELATIONS.

Similarly, given that the knowledge of Search Engine Optimization is crucial in Digital media coordination, as it helps to drive and gain web or online traffic both in quality and quantity.

Hence, Claire also needs to know about Search Engine Optimization.

Individuals who break into computer systems with the intention of doing damage are called​ _____________.

a. white hats
b. ​e-criminals
c. hackers
d. keyloggers
e. black hats

Answers

I think the answer is hackers

The individuals who made the unethical entry into a person's system with intentions of damage are termed, hackers. Thus, option C is correct.

What is a computer system?

A computer system has been given as the network connection of the hardware and the software equipped with the objects that are used for the operation of the computer.

The computer system with the internet connection has been able to make the connection to the world. as well the invention mediates the work with ease as well.

The system thereby has the access to the passwords and the personal details of an individual as well. There are individuals who try to make access the computer system in an unethical way and intended to damage the system.

The computer viruses are used for the following purpose and were drawn by the hackers. Thus, option C is correct.

Learn more about the computer system, here:

https://brainly.com/question/14253652

#SPJ2

For risk monitoring, what are some techniques or tools you can implement in each of the seven domains of a typical IT infrastructure to help mitigate risk

Answers

Answer:

 a. User Domain: Create awareness for acceptable user-policies and security risk to educate employees of pending risk.

b. Workstation Domain: Install anti-virus and constantly update the system software.

c. LAN Domain:  Access control list or ACL should be configured in routers and port security in switches to avoid hackers physically connecting to the network.

d. LAN-to-WAN Domain: Configure firewalls and intrusion detection and prevention protocols to mitigate unwanted access.

e. WAN Domain: Configure demilitarized or demarcation zone to provide secure access and prevent unwanted users from accessing network information.

f. Remote Access Domain: The use of VPNs to grant remote access to users or employees working from home and internet protocol security (IPsec) to encrypt the packet transmission.

g. Systems/Applications Domain: Administration should be well trained and ensure to get security software patches from appropriate vendors and testing them before use.

Explanation:

Risk monitoring is one of the IT infrastructure risks management plan that observes and analyzes the threats of risk in an IT infrastructure.

Mathematics and computer science share many concepts.
One of them,
occurs when something is defined in terms of itself.

Answers

Answer:

Recursion

Explanation:

Answer: recursion

Explanation:

Consider the use of 1000-bit frames on a 1-Mbps satellite channel with a 270-ms delay. What is the maximum link utilization for,
a. Stop-and-wait flow control?
b. Continuous flow control with a window size of 7?
c. Continuous flow control with a window size of 127?

Answers

i feel as if it would be B.
Other Questions
What were some of the challenges Twain faced in his life? If the production rate is 1,325 cookies per hour at a bakery, how many cookies will be produced in an 8 hour shift? How do you know which standardized test statistics you will use? A Z or T? It costs $20 to get into Dollywood. Each ride costs an extra $4. f(x) = 20 + 4x is a function representing the total cost of a trip to Dollywood. An animal dies in mud, decomposes, and leaves an imprint, which is later filled by sediment to form a solid copy ofthe original organism.How is this fossil different from fossils of preserved remains?3Only hard tissue is preserved.O Hard and soft tissues are preserved.O Only soft tissue is preserved.O There is little change to the preserved organism. What is the value of | 3 |? What is the equation of the line that passes through the point(6,4) and has a slope of -2/3 Which THREE of the following words 1 pointhave similar meanings?rancidedibletainteddigestiblepalatable Kayla has a older sister and a younger sister. her older sister is one year more than twice Kayla's age. Kayla's younger sister is three years younger than she is. the sum of their ages is 26. find Kayla's age did the kkk hold any power in the south. Which diagram represents folded rock layers? please help me, answer all 4 and ill give 5 stars, like, and brainliest~ There are four different types of representational art. What are the names of all four types? Also, choose one of the four to explain. What does it mean and what would it look like?~ What is abstract art? Can you think of an example of an abstract artist?Please give a description of pointillism. Include the famous example of pointillism mentioned in the unit and explain what that piece looks like.~ How would you explain surrealism to someone who had never seen it before? Please include the example of surrealism from the unit in your explanation.~ The Russian artist Wassily Kandinsky believed that color could show emotions. Please fill in the emotions that he believed each color showed. HEY guys can yall help me im trying to get caught up on school work before november 30.What techniques are required to accept constructive criticism? Select all that apply.A. not interrupting or speaking until the other person is finished making a pointB. filing a formal complaint with human resources to make sure your point of view is documentedC. not frowning, sneering, or defensively folding arms in front of you The ____ likes to play a lot.a. lionb. gorillac. snaked. monkey 5)Experiments with gold foil indicated that atomsA)usually have a uniform distribution of positive chargesB)usually have a uniform distribution of negative chargesC)contain a positively charged, dense centerD)contain a negatively charged, dense center what is the history of movement enhancement? Stay at least _____ behind the vehicle ahead of you at all times. A. 3 seconds B. 4 seconds C. 3 car lengths D. 4 car lengths How would you compare the early modern economy to economic conditions in medieval Europe? What is the role of mitochondria in eukaryotic cells? A. to transport materials throughout the cell. B. to provide structure and mechanical support for the cell c. to regulate the flow of materials in and out of the cell.D. to generate chemical energy that powers the cell How did Bessie Blount first learn how to read?