Given the following code segment, what is output after "result = "? int x = 1, y = 2, z = 3; cout << "result = " << (x < y ? y : x) << endl;

a. 1
b. 2
c. 3
d. 4

Answers

Answer 1

Answer:

b. 2

Explanation:


Related Questions

if i press the home button of the phone so it opens but how it opens?
Please answer with explanation ​

Answers

Answer:

by its system software

Explanation:

it is programmes by programmers like that its language is binary (0,1) so thats y when we switch it it gets to on just because that button is programmed like that if the home button wasn't on the mobile the mobile would not work it would be useless...

Whats the difference between pseudocode and python? please hurry!!! brainliest for fastest! :3 50 POINTS!!!

Answers

Answer:

Pseudocode is a more readable coding language that is used for repeating steps, however, is similar to python. It may exclude certain functions or details due to its level of readability, which has pros and cons.

Python, however, is a multi-purpose fun coding language that is, similar to HTML and Pseudocode, good for beginners. Python is simple and easy to learn. You can make games, store data, get user input, and much more.

What is the error in the following pseudocode?
// This program uses an array to display five names.
Constant Integer SIZE = 5
Declare String names[SIZE] = "Meg", "Jack", "Steve", "Bill", "Lisa"
Declare Integer index
For index = 0 To SIZE
Display names[index]
End For

Answers

I do not know the answers sorryy

identify and state the value of hardware components​

Answers

Answer:

Explanation:

Hardware is the most visible part of any information system: the equipment such as computers, scanners and printers that is used to capture data, transform it and present it to the user as output. Although we will focus mainly on the personal

Should spreadsheets be used to capture the results of a science experiment?

YES
NO

Answers

Answer:

Yes

Explanation:

Spreadsheets should be used to capture the results of science experiments because they are good for sorting data. They make results easier and information easier to see and use.

No.

Graphs are often an excellent way to display your results. In fact, most good science fair projects have at least one graph. For any type of graph: Generally, you should place your independent variable on the x-axis of your graph and the dependent variable on the y-axis.

differences between the first four generations of computers​

Answers

Answer:

Explanation:

These first generation computer were mainly used for scientific computations. Some examples of these computers are ENIAC, EDVAC, EDSAC, UNIVAC I and IBM 701.

Use python
def exec_2(f):
f()
f()
any function that is passed into exec_2() will be executed twice without parameters. Your task is to write a function exec_4(f) that takes in a function f as a parameter and executes the function f 4 times using the function exec_2. The function f in this case will draw a cute koala bear, and, in conjunction with, exec_4(), you will draw 4 koalas on the same tree! Suppress the newline in the print statement for the koala, this can be done using print's end argument
def exec_2(f):
f()
f()
def exec_4(f):
# define this function using exec_2
# define a new function here that prints out the koala once
# use your function and exec_4 to draw 4 koala bears!

Answers

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.

what are the five generations of computer based on computing characteristics​

Answers


Second generation 1950s-1960s Transistor based


Third generation 1960s-1970s Integrated circuit based


Fourth generation 1970s-present Microprocessor based


Fifth generation The present and the future Artificial intelligence

what are the picture affect features​

Answers

Answer: ????????????????????????????

Explanation:

TRUE or FALSE.

2.2 Connectivity is the term used to describe the ability to connect to the internet by using a device
such as a computer or cell phone

Answers

Answer:

True

Explanation:

Because it is the very best way to get it done

When you create a calculated item for a field in a PivotTable, it appears as a new item within the field. Question 4 options: True False

Answers

When you create a calculated item for a field in a PivotTable, it appears as a new item within the field is a false statement.

What is a calculated item in a pivot table?

A Calculated Item is known to be a kind of custom formula that is seen in an Excel pivot table.

It is known to be one that can use the sum of other items in the same field. For example, when a person calculate the sum of 2 other items in a field. Note that Calculated items are not depicted or shown in the PivotTable Field List.

Learn more about PivotTable from

https://brainly.com/question/15214258

another one please tysm​

Answers

Explanation:

5-blue

6-Mixing primary colors creates secondary colors. for example: if you mix blue and yellow, you get green

7- orange

8- shape

Who is the traitor of UA?

1 Karishma

2 Yuga Aoyama

3 Denki

4 Mineta

Answers

Answer:

your answer is yuga Aoyama

Explain two methods which the operating system may use to maintain the security of data stored on disk

Answers

Answer:

Measures that can be taken to keep data secure include: making regular backups of files (backup copies should be stored in fireproof safes or in another building) protecting yourself against viruses by running anti-virus software. using a system of passwords so that access to data is restricted.

Explanation:

The methods that the operating system may use to maintain security  are:

Regularly logging off or locking.

The use of data encryption methods to code data.

How do operating systems keeps security of data?

In the areas of Security utilities, there is often the use of encryption  to maintain data.

In this process, one can encrypt data as at the time it is been saved, or when one is trying to transmit it over a network. One can also use anti-virus software so as to check and blocks viruses.

Conclusively, the use of the methods above in the operating system may can help you to maintain security.

Learn more about operating system from

https://brainly.com/question/22811693

#SPJ2

how do artificial intelligence works?

Answers

Explanation:

AI systems work by combining large sets of data with intelligent, iterative processing algorithms to learn from patterns and features in the data that they analyze. Each time an AI system runs a round of data processing, it tests and measures its own performance and develops additional expertise

AI systems learn from the patterns and features in the data they study by combining vast volumes of data with sophisticated, iterative processing methods.

Each time an AI system processes data, it evaluates and measures its own performance and gains further expertise.

Due to the fact that AI never requires a break, it can perform hundreds, thousands, or even millions of tasks extremely quickly, acquiring a great quantity of knowledge in a short period of time and becoming extremely capable at whatever work it is trained to perform.

However, the key to properly understanding how AI works is to recognize that it is not a single computer program or application, but a complete discipline or science.

The goal of AI science is to develop a computer system capable of imitating human behavior in order to tackle complicated issues using human-like cognitive processes.

AI systems accomplish this goal by utilizing a variety of methodologies and processes, as well as a diverse array of different technology.

The while loop is also known as what kind of a loop? entry-control loop operational loop infinite loop user-control loop

Answers

Entry control loop. Because a while loop can be infinite or not based on whether Boolean given is T or F. So we need to know the preexisting condition before we can solve it.

Should spreadsheets be used to keep score of a baseball game?

YES
NO

Answers

Yes, a spreadsheet can do the maths for you

Fill in the blank with the correct response.
Fast Ethernet is ______times faster than Ethernet.

Answers

Answer: 100 Mbps

Explanation: Fast Ethernet runs 100 Mbps and Ethernet offers up to 1 Gbps.

Fast Ethernet is 10 times faster than Ethernet.

What is Ethernet?

Metcalfe modified the name to "Ethernet" in 1973. He did this to demonstrate that any computer, not just Alto's, would be supported by the technology he had developed.

He chose the term "Ether" to refer to the physical medium that carries bits to stations, which is a crucial aspect of the system. Fast Ethernet transmission, which is at least 10 times faster than standard Ethernet, helps maintain compatible connections to high-speed servers.

It reduces bandwidth bottlenecks for network systems running multiple IP video cameras and the Internet of Things and supports seamlessly complex networks that simultaneously run a number of bandwidth-hungry software programs.

Therefore, fast Ethernet is 10 times faster than Ethernet.

To learn more about Ethernet, refer to the link:

https://brainly.com/question/13441312

#SPJ2

12 points. Fiona is starting to utilize the protection capabilities of Excel 2016. For the Lock or Unlock Cells function to work, which option should be enabled?

The Protect Workbook function needs to be enabled.

No functions need to be enabled other than the lock or unlock cells options.

The worksheet must be saved before the cells will become locked or unlocked.

The Protect Worksheet function needs to be enabled.

Answers

Answer:

The answer is D

Explanation:

just took the test on ed

In Microsoft Excel 2016, for the Lock or Unlock Cells function to work: D. The Protect Worksheet function needs to be enabled.

Microsoft Excel can be defined as a software application that is designed and developed by Microsoft Inc., to avail its end users the ability to analyze and visualize spreadsheet documents.

In Microsoft Excel, a Lock is used to prevent the editing and deleting of data stored in specific cells and ranges in a protected worksheet.

On the other hand, the Unlock Cells function allows data stored in specific cells and ranges in a protected worksheet to be edited and deleted.

In conclusion, Fiona must enable the Protect Worksheet function for the Lock or Unlock Cells function to work in Microsoft Excel 2016.

Read more: https://brainly.com/question/14299634

Given that arrayIntValues [MAX_ROWS][MAX_COLUMNS] is a 2 dimensional array of positive integers, write a C++ function howManyEven to find the total number of even elements in the array. It should have input parameter array arrayIntValues. The function should return an integer.

Answers

Answer:

Follows are the method definition to this question:

int even(int A[MAX_ROWS][MAX_COLUMNS], int length,int width)//defining a method even,that accept 2D array and two integer variables  

{

int E_num = 0;//defining an integer variable E_num that holds a vlue 0

for (int i = 0; i < length; ++i)//declare for loop for row count

{

for (int j = 0; j < width; ++j)//declare for loop for column count

{

if(A[i][j]%2 == 0 )//use if block that check even number in array  

{

E_num++;//incrementing the value of E_num  

}

}

}

return E_num;//return E_num value

}

Explanation:

In the above code, a method "even" is defined, which accepts a 2D array "A" and two integers " length and width" in its parameter.

Inside the method, an integer variable "E_num" is defined that uses two for loop and an if block for the count the even numbers which are available on the 2D array.

please find the attahced file for method ouput.  

what is the use of a router​

Answers

Answer:

Hope This Helps

A router is a networking device that forwards data packets between computer networks. Routers perform the traffic directing functions on the Internet. Data sent through the internet, such as a web page or email, is in the form of data packets. A packet is typically forwarded from one router to another router through the networks that constitute an internetwork until it reaches its destination node.

Explanation:

Answer:

It connects multiple devices together.

It transmits data to it's correct destination on a network through a process known as routing.

CHALLENGE ACTIVITY 5.2.3: Basic while loop expression. Write a while loop that prints userNum divided by 4 (integer division) until reaching 2 or less. Follow each number by a space. Example output for userNum = 160: 40 10 2 Note: These activities may test code with different test values. This activity will perform four tests, with userNum = 160, then with userNum = 8, then with userNum = 0, then with userNum = -1. See "How to Use zyBooks". Also note: If the submitted code has an infinite loop, the system will stop running the code after a few seconds, and report "Programend never reached." The system doesn't print the test case that caused the reported message.

Answers

Answer:

input with 160

output: 40 10 2

Explanation:

import java.util.Scanner;

//Define the class divideFour

public class divideFour

{

  public static void main(String[] args)

  {

      //Declaration of variables as integer

      int userNum;

      //set an input

      userNum = 160;

      //Run the while loop until the conditions are not satisfied.

      while(userNum>2)

      {

          //Divide userNum by 4 and store it in the same.

          userNum = userNum/4;

          //Print the new value of the userNum

          System.out.print(userNum+" ");

      }

      System.out.print("");

  }

}

What is the purpose of a register in a CPU? Describe three types of registers.

Answers

Answer:

I hope this answer is correct

Explanation:

Internal registers include the instruction register (IR), memory buffer register (MBR), memory data register (MDR), and memory address register (MAR). The instruction register fetches instructions from the program counter (PC) and holds each instruction as it is executed by the processor.

Which of the following can be used to offer a higher impedance to all frequencies except the resonant frequency?

A. RL time constant circuit
B. Parallel LC circuit
C. RC time constant circuit
D. Series LC circuit

Answers

Answer:

  D. Series LC circuit

Explanation:

Impedance changes monotonically with frequency for an RC or RL circuit. A parallel LC circuit has a maximum of impedance at resonance. Only the series LC circuit will have its lowest impedance at resonance, and a higher impedance elsewhere in the frequency spectrum.

Answer:

D. Series LC circuit

Explanation:

can be used to offer a higher impedance to all frequencies except the resonant frequency.

4.11 LAB: Remove gray from RGBSummary: Given integer values for red, green, and blue, subtract the gray from each value.Computers represent color by combining the sub-colors red, green, and blue (rgb). Each sub-color's value can range from 0 to 255. Thus (255, 0, 0) is bright red, (130, 0, 130) is a medium purple, (0, 0, 0) is black, (255, 255, 255) is white, and (40, 40, 40) is a dark gray. (130, 50, 130) is a faded purple, due to the (50, 50, 50) gray part. (In other words, equal amounts of red, green, blue yield gray).Given values for red, green, and blue, remove the gray part.Ex: If the input is:13050130the output is:80 0 80Find the smallest value, and then subtract it from all three values, thus removing the gray.Note: This page converts rgb values into colors.LAB

Answers

Answer:

Written in Python

rgb = []

colr = []

for i in range(0,3):

     inp = int(input("Input: "))

     if (inp >=0 and inp<=255):

           rgb.append(inp)

     else:

           print("Range is 0 to 255")

           exit()

colr.extend(rgb)

rgb.sort()

for i in range(0,3):

     print(colr[i] - rgb[0])

Explanation:

The next two lines declares two empty lists

rgb = []

colr = []

The following iteration lets user input into rgb list

for i in range(0,3):

     inp = int(input("Input: "))

     if (inp >=0 and inp<=255):

           rgb.append(inp)

     else:

           print("Range is 0 to 255")

           exit()

This line copies the content of rgb to colr

colr.extend(rgb)

This line sorts list rgb

rgb.sort()

This iteration calculates and prints the difference between each individual input and the smallest of the inputs

for i in range(0,3):

     print(colr[i] - rgb[0])

analyze the ethical issues in the use of information technology in Multinational company (MNC) and support you answer with one example

Answers

Answer:

Explanation:

Multinational Companies tend to have millions of users from all over the globe who use their services and in doing so provide their information. This information gets saved on the databases of these companies. It is then up to the company on how they will use this information. This is where ethicality comes into play. A company can act ethically and protect the information that has been entrusted to them by their user, or they can act unethically and use the users' personal data to make profits. It has recently come to light that some companies have been using users' private data and would sell it to other companies for profit. These buying companies would then use the data for a variety of things such as ad targeting and statistics. These companies profited massively and the actual owners of the data did not, which makes this incredibly unethical.

With respect to computer hardware, what is a major difference between Mac OS and Windows or Linux?

Answers

Answer:

Key Differences Between Linux and MAC and Windows

Windows is dominant over the other two as 90% of users prefer Windows. Linux is the least used operating system with users accounting for 1%. ... MAC is costlier than Windows and the user is forced to buy a MAC system built by Apple.

Fill in the blank to complete the sentence.
If you only want to use the localtime function, you can load just that one function into active memory using the following line of code.

from _______ import localtime()

(Sorry for bad picture) ​

Answers

Answer:

The correct answer is time

Explanation:

from time import localtime()

Using touch or mouse to move or copy cells is calLed_______.

Answers

Answer:

The answer to this question is given below in the explanation section.

Explanation:

Using touch or mouse to move or copy cells is called Drag and Drop.

It can be called dragging when moving, or dragging or filling when copying. If you are using Fill Handle, you are filling, but you can also drag to copy something to a non-contiguous location with the mouse,  while holding the Ctrl key.

use the __________ to measure small amount of liguid

Answers

The volumetric flask is use to measure
Other Questions
Which of the following numbers is a factor of 555555?Choose 1 answer: The English Bill of Rights became important to America's founding documents, especially the ____ added to the Constitution. Which are examples of renewable energy? Check all that apply.geothermal energysunlightwindmethanewater Craig saved $10,950 in a year. He saved $75 more than what he saved the previousmonth. How much did he save in the first month? WHO IS REALLY GOOD IN SPANISH?Son las 11:30 de la noche. Me voy a acostar, ____.Me preocupo.Estoy en la luna.Estoy a dieta.Me caigo de sueo. Pablo y Roberto son muy antipticos What is the meaning of Taxonomy? How does the poem's rhyme scheme develop its tone? A The poem follows an AABA BBCB CCDC DDDD end rhyme scheme; this flowing, alternating scheme contributes to the soft, almost lullaby-like quality of tone. B The poem follows an AABA BBCB CCDC DDDD end rhyme scheme; this repetitive rhyme, almost like a chant, contributes to the eerie tone. C The poem is composed of rhyming couplets, creating a musical diction and beat; this contributes to the playful tone. D The poem is composed of rhyming stanzas (i.E. AAAA BBBB CCCC DDDD); this consistent, almost blocky rhyme contributes to the solemn ton Read the excerpt from chapter 10 of Animal Farm.But the luxuries of which Snowball had once taught theanimals to dream, the stalls with electric light and hotand cold water, and the three-day week, were no longertalked about. Napoleon had denounced such ideas ascontrary to the spirit of Animalism. The truest happiness,he said, lay in working hard and living frugally.How does Orwell use irony in this excerpt?The text shows that if the animals work harder, theywill have luxuries they dreamed of.O The text shows that Napoleon's dreams conflict withthe dreams of the animals.O The text shows that the animals expected a differentoutcome than the reality they are facing.The text shows that Snowball and Napoleon nevermeant to mislead the other animals. In which situation could a case go to a federal court?Mr. Jones gets pulled over for a speeding ticket.Mr. Clark gets arrested for vandalizing a school playground.Mr. Fields has to go to court over child custody.Mrs. Blanchard is arrested for hijacking an airplane What do I do if my cat starts climbing my ceiling. Please answer asap 15) An electrician charges $15 per service call plus $25 an hour. The total bill for a recent job was $90. Howmany hours did the electrician work? one of your parents ___ required to be at the meeting. are, am, is were A rectangle is inscribed in a circle17 in.18 in.15 in.Part ACalculate the exact area of the cirde. Use the key on the calculator. Round answer to the nearest hundredth if necessarysquare inchesPart BCalculate the area of the rectangle. Round answer to the nearest hundredth if necessaryA=square inchesPartCalculate the area of the shaded regionArea of the shaded regionsquare inches There where 6 karens.2 of them whanted to speek to the manger.There where 2 mangers and 1 of te mangers was out sick how many karens and mangers are in the store?[tex]6+1=[/tex] Burning question: is it possible for life to thrive on earth without soil? are small unmarked stones with sharp edges evidence of early humans? why or why not? how the formal and informal powers of the president impact the executive branch?help me help me help me help me help me please if humans didn't exist what would the world be right now and the life on it what fraction of the year is 3 month? 3/4 ___________________