subject

(a) if the following switch statement were implemented using a jump table, how many elements would the table contain?

would it make sense to use a jump table to implement this switch statement? why or why not? if not then what type of implementation will be more suitable?

why?

switch (i) {

case 40: j = a; break;

case 41: j = b; break;

case 42: j = c; break;

case 43: j = d; break;

case 44: j = e; break;

case 45: j = r; break;

case 46: j = g; break;

}

(b) answer the same questions as in part (a), using the following switch statement instead:

switch (i) {

case 20: j = a; break;

case 67: j = b; break;

case 97: j = c; break;

case 400: j = d; break;

case 310: j = e; break;

case 10: j = f; break;

}

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 31.01.2019 17:10
The great length of north america causes the climate to be varied. true false
Answers: 2
question
Computers and Technology, 30.01.2019 08:40
In he example code, what does the title attribute create? a tool tip an element a source a markup
Answers: 1
question
Computers and Technology, 24.01.2019 22:23
Use the keyword strategy to remember the meaning of the following word. the meaning for the word has been provided. write your keyword and describe the picture you would create in your mind. obfuscate: to make something so confusing that it is difficult to understand.
Answers: 2
question
Computers and Technology, 22.01.2019 16:38
These factors limit the ability to attach files to e-mail messages. location of sender recipient's ability to open file size of file type of operating system used
Answers: 1
You know the right answer?
(a) if the following switch statement were implemented using a jump table, how many elements would t...
Questions
question
English, 20.04.2020 22:10
question
Chemistry, 20.04.2020 22:10
Questions on the website: 6616170