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
agasfer [191]
2 years ago
15

A numeric test score is to be converted to a letter grade of A, B, or C according to the following rules: A score greater than 9

0 is considered an A; a score between 80 and 90, inclusive, is considered a B; and any other score is considered a C. What code segments will assign the correct letter grade to grade based on the value of the variable score?
Computers and Technology
1 answer:
arlik [135]2 years ago
7 0

The code segment makes use of conditional statements.

Conditional statements in programming are used to make decisions

The code segment in C++ is as follows

if (score > 90) {

grade = 'A';

}

else if (score >= 80 && score < =90) {

grade = 'B';

}

else {

grade = 'C';

}

The above code segments take the score, make comparison, and then determine the appropriate letter grade.

Read more about code segments at:

brainly.com/question/20475581

You might be interested in
With a(n) ______, a search engine will show ads that have the keyword typed exactly as the searcher used, but may also have othe
allsm [11]

Answer:

modified broad match.

Explanation:

A Search engine is an internet resource or service that searches for keywords or categories specified by the end user and then displays (shows) a list of website which matches or have informations similar to the query. Some examples of popular search engines are Goo-gle, Bing, Yahoo, etc.

At the retrieving stage of a web search, the search engine queries its database using a retrieval algorithm to extract the necessary and related terms to the search. After obtaining the search terms, the stored web addresses that are related to the search is then displayed.

There are different types of matching techniques used in configuring a search engine and these includes;

I. Exact match.

II. Phrase match.

III. Broad match.

IV. Modified broad match

When a modified broad match is used, the search engine shows adverts that have the keyword typed exactly as the searcher used, but may also include other words within the search term.

Hence, the name modified because it avail users other options by including other words within the search.

5 0
2 years ago
Some computer engineering students decided to revise the LC-3 for their senior project. In designing the LC-4, they decided to c
Bezzdna [24]

Some computer engineering students decided to revise the LC-3 for their senior project.  KBSR and the DSR into one status register: the IOSR (the input/output status register). IOSR[15] is the keyboard device Ready bit and IOSR[14] is the display device Ready bit can be done in LC-3.

LC-4 is a poor design.

Explanation:

LC-3, is a type of computer educational programming language, an assembly language, which is a type of low-level programming language.

It features a relatively simple instruction set, but can be used to write moderately complex assembly programs, and is a theoretically viable target for a C compiler. The language is less complex than x86 assembly but has many features similar to those in more complex languages. These features make it useful for beginning instruction, so it is most often used to teach fundamentals of programming and computer architecture to computer science and computer engineering students.

The LC-3 specifies a word size of 16 bits for its registers and uses a 16-bit addressable memory with a 216-location address space. The register file contains eight registers, referred to by number as R0 through R7. All of the registers are general-purpose in that they may be freely used by any of the instructions that can write to the register file, but in some contexts (such as translating from C code to LC-3 assembly) some of the registers are used for special purposes.

When a character is typed:

  • Its ASCII code is placed in bits [7:0] of KBDR  (bits [15:8] are always zero)
  • The “ready bit” (KBSR[15]) is set to one
  • Keyboard is disabled -- any typed characters will be ignored

When KBDR is read:

  • KBSR[15] is set to zero
  • Keyboard is enabled
  • Alternative implementation: buffering keyboard input
8 0
3 years ago
The first and second numbers in the Fibonacci sequence are both 1. After that, each subsequent number is the sum of the two prec
vlabodo [156]

Answer:

In Python:

def fib(nterms):

   n1, n2 = 1, 1

   count = 0

   while count < nterms:

       term = n1

       nth = n1 + n2

       n1 = n2

       n2 = nth

       count += 1

   return term

Explanation:

This line defines the function

def fib(nterms):

This line initializes the first and second terms to 1

   n1, n2 = 1, 1

This line initializes the Fibonacci count to 0

   count = 0

The following while loops gets the number at the position of nterms

<em>   while count < nterms: </em>

<em>        term = n1 </em>

<em>        nth = n1 + n2 </em>

<em>        n1 = n2 </em>

<em>        n2 = nth </em>

<em>        count += 1 </em>

This returns the Fibonnaci term

   return term

7 0
3 years ago
after installing a second hard drive what needs to be done to the hard drive and what do these 2 tasks do?
PIT_PIT [208]
To make it useable, the disk first needs to be subdivided into logical volumes, then formate, so that it is readable by the systems.
6 0
3 years ago
Explain what might happen if two stations are accidentally assigned the same hardware address?
Firdavs [7]

Answer: If two different station are addressed with the same hardware address then there are chances of occurrence of the failure in the network at irregular intervals.The failure or error will occur because of the both the devices are seen as one by the network due to same address.

An intelligent network system id used ,it can identify the error can help in the prevention of the failure.Other option for configuring the situation is assigning the MAC(media access control)address to devices which are unique in nature thus, no device can have same address.

5 0
3 years ago
Other questions:
  • Ben's team is working on an English project. The members want to see everyone's progress on their part of the project. What tech
    7·2 answers
  • The user can set their own computer hostname and username. Which stage of the hardware lifecycle does this scenario belong to?
    6·1 answer
  • Design a hierarchy c hart or flowchart for a program that calculates the current balance in a savin gs account. The program must
    8·1 answer
  • _______ tools enable people to connect and exchange ideas.
    7·2 answers
  • What does f.i.r.s.t stand for in robotics
    15·1 answer
  • We can sort a given set of n numbers by first building a binary search tree containing these numbers (using Tree-Insert repeated
    12·1 answer
  • You are in the middle of a big project at work. all of your work files are on a server at the office. you want to be able to acc
    14·1 answer
  • Why are medical related professions and human resources important? ​
    8·1 answer
  • PLEASE HELP ASAP!!! 99 POINTS FOR 3 MULTIPLE CHOICE QUESTIONS!!! PLEASE ANSWER ALL!!!
    8·1 answer
  • Jamal wants to create a program that will play music during the afternoon. Which kind of loop should be used in the program?
    6·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!