Convert the following pseudo code into assembly code.

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter8: Arrays
Section: Chapter Questions
Problem 15RQ
icon
Related questions
Question

Please use while loop. this is for assembly language

• Convert the following pseudo code into assembly code.
int array_list[] = {10, 11, 13, 18, 21, 23, 24, 17, 45};
int array_size = sizeof array_list / sizeof sample;
int index = 0;
// index for while loop
int sum = 0;
// accumulate the result
O for (current_size = array_size ; current_size > 0 ; current_size--){
while ( index < current_size){
if( array_list[index] is even ){
sum += array_list[index];
}
index += 1;
• Store the result in the variable
sum.
Transcribed Image Text:• Convert the following pseudo code into assembly code. int array_list[] = {10, 11, 13, 18, 21, 23, 24, 17, 45}; int array_size = sizeof array_list / sizeof sample; int index = 0; // index for while loop int sum = 0; // accumulate the result O for (current_size = array_size ; current_size > 0 ; current_size--){ while ( index < current_size){ if( array_list[index] is even ){ sum += array_list[index]; } index += 1; • Store the result in the variable sum.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Fundamentals of Computer System
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
New Perspectives on HTML5, CSS3, and JavaScript
New Perspectives on HTML5, CSS3, and JavaScript
Computer Science
ISBN:
9781305503922
Author:
Patrick M. Carey
Publisher:
Cengage Learning