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
Alinara [238K]
3 years ago
10

Different between if/else structure and switchstructure in c and c++, why switch statements is more efficientthan using multiple

if/else statements?
Computers and Technology
1 answer:
ad-work [718]3 years ago
7 0

Answer:

Explanation:

Hello, great question. These types are questions are the beginning steps for learning more advanced Coding Problems.

If/Else statements receives an input and compares it to a true of false statement, if it is true then one function is called. Otherwise another function is called. IF/Else statements only have two outcomes which is why they are many times nested one on top of the other to be able to produce more outcomes.

Switch Statements receive and input and compares it to a set of predefined answers. If the right answer is found then the function relating to that answer is called. Otherwise the default function is called.

IF/Else is only more efficient than Switch statements if the inputted value is not predictable enough to make a predefined set.

I hope this answered your question. If you have any more questions feel free to ask away at Brainly.

You might be interested in
Importancia de la química en la vida cotidiana​
maks197457 [2]

Answer:

chemistry is very important because everything you do is chemistry . our body is made up of chemicals . chemicals reactions occurs when be breathe ,eat , etc . All matter is made of chemicals so that chemistry is very important in our life

5 0
3 years ago
Company ABC has always used passwords to protect the highly confidential information in their company. Recently, someone who was
Leno4ka [110]
Company ABC should use passwords but also have them use a code so that not just anyone can get in. Kinda like facebook.
3 0
3 years ago
What is the output of a hash function called?
ruslelena [56]

Answer:

cryptographic hash collision.

Explanation:

4 0
3 years ago
Which of these is not used by analysts when adopting CASE tools? (1 point) (Points : 1.5) communicating more effectively with us
mojhsa [17]

Answer: expediting the local area network

Explanation: Case tools are the tools or service that helps in the software development but the automatic activity. This tool can be applied on various applications like mobile apps, E-commerce websites etc.

Analyst focus on the features like improving productivity ,low time consumption,integration of the work and making the communication better with the users ,helps in producing large amount of the documents etc.

The only factor not accepted by analyst is accomplishing the operation in the LAN(local area network) as it does not facilitates this operation because it is not software development process.

4 0
4 years ago
Please I have been having a problem with this assignment of mine but I have not gotten an answer. Idiot know if anybody could be
ICE Princess25 [194]

Answer:

ummm

Explanation:

your on your own it doesn't makes since

3 0
3 years ago
Other questions:
  • How many total numbers can be represented with an 8-bit binary (base-2) system?
    9·1 answer
  • Which of the following cannot be performed from the windows task manager?
    15·2 answers
  • Decision trees are onlyapplicable to problems under certainty.<br> True<br> False
    11·1 answer
  • When admitting digital evidence at trial, the issue of ________ comes up when the evidence involves computer-generated records.
    13·1 answer
  • The _____ handles the instructions for your computer to start up before the operating system is loaded.
    10·1 answer
  • What number system that has 16 numerals
    11·2 answers
  • Trudy is preparing a reply to an email message. Before she could send out the message, she is called for a meeting. If Trudy has
    6·2 answers
  • Provide a status report to your classmates and instructor. Describe any modifications that you have made to the design or docume
    10·1 answer
  • What is computer software​
    9·1 answer
  • Felicia's Wi-Fi connection to her phone is extremely slow. However, her
    7·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!