Consider the following 0x86 program: .data array DWORD 1,2,3,4,5,6,7,8,9 aravSize -(S-array)/4 ; array .code main PROC...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Consider the following 0x86 program: .data array DWORD 1,2,3,4,5,6,7,8,9 aravSize -(S-array)/4 ; array .code main PROC mov ecx,arraySize-1 mov esi.OFFSET array L1: mov eax. [esi] sda mov bx,2 idiv bx add esi,4 smp edx,0 je lbl jmp, next Ibl: mov eax.[esi] shr eax,1 mov [esi],eax next: loop L1 exit main ENDP END main What is the content of the array at the end of the program? a) 1,1,3,2,5,3,7,4,9 b) 0,1,1,2,2,3,3,4,4 c) 1,2,1,4,2,3,7,8,4 d) 0,2,1,4,2,6,3,8,4 Consider the following 0x86 program: .data array DWORD 1,2,3,4,5,6,7,8,9 aravSize -(S-array)/4 ; array .code main PROC mov ecx,arraySize-1 mov esi.OFFSET array L1: mov eax. [esi] sda mov bx,2 idiv bx add esi,4 smp edx,0 je lbl jmp, next Ibl: mov eax.[esi] shr eax,1 mov [esi],eax next: loop L1 exit main ENDP END main What is the content of the array at the end of the program? a) 1,1,3,2,5,3,7,4,9 b) 0,1,1,2,2,3,3,4,4 c) 1,2,1,4,2,3,7,8,4 d) 0,2,1,4,2,6,3,8,4
Expert Answer:
Answer rating: 100% (QA)
Answer First of all you can simplify your code Copy Code reverseLoop mov eax esi move the element in esi to eax mov ebx edi move the element in edi to ... View the full answer
Related Book For
An Introduction to the Mathematics of Financial Derivatives
ISBN: 978-0123846822
3rd edition
Authors: Ali Hirsa, Salih N. Neftci
Posted Date:
Students also viewed these programming questions
-
Allergan is a major pharmaceutical firm. You work for Allergan's CFO and are evaluating a major and expensive drug trial. The drug trial would require an investment of $95 million today If the trial...
-
Consider the MPS record below Wk 1 2 3 4 5 6 Forecast 15 25 9 15 22 5 Orders 7 10 10 10 Available ATP MPS On hand = 5, Lot size = 30 a. Complete the MPS record b. Update the record from part a -...
-
Determine CPI, ETC (1), and EAC. Activity Total PV 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 6 6 2 20 10 10 3 30 9 6 6 6 3 4 20 8 2 5 5 5 16 4 4 4 4 6 18 9 9 7 8 4 4 Status Report: Ending Period 5 Task %...
-
The table lists the actual annual cost y to drive a midsize car 15,000 miles per year for selected years X. (a) Predict whether the correlation coefficient is positive, negative, or zero. (b) Find a...
-
Use the n-IG system state TESTcalc to (a) determine the chemical potential (k) of hydrogen in an equimolar mixture of hydrogen and carbon dioxide at 100 kPa and 300 K. Plot how the chemical potential...
-
As of September 4, 2016, the film Suicide Squad had an average rating of 3.7 out of 5 based on 117,323 viewer ratings (Rotten Tomatoes website). How are the viewer ratings of Suicide Squad related to...
-
Data extracted from a year-end balance sheet are shown below. Compute the working capital for this firm. What would the current ratio be, and what is the significance for this firm? Accounts payable...
-
You are considering investing in a company that cultivates abalone for sale to local restaurants. Use the following information: Sales price per abalone ............. = $ 35 Variable costs per...
-
Zamphir Jets manufactures luxury jets for corporate use. Its main production line is devoted to manufacturing the Z 1 jet, which is its standardized product offering. At any point in time, 2 0 to 3 0...
-
Prove that Then show that the regions under the hyperbola over the intervals [1, 2], [2, 4], [4, 8], . . . all have the same area (Figure 3). bla 1 1 L = = dx = fi = = dx te - Ja x X dx for a, b 0.
-
Prepare a trial balance for Kenny's Lawn Service as of September 30, 20--. List the accounts in the order of Assets, Liabilities, Owner's equity, Revenue, and Expenses. If an amount box does not...
-
A polling organization conducts a study to estimate the percentage of households that have both parents sharing equally in household chores. It mails a questionnaire to 1228 randomly selected...
-
To help assess student learning in her music theory courses, a music professor at a community college implemented pre- and post-tests for her music theory students. A knowledge-gained score was...
-
Designing an Experiment Researchers wish to know if there is a link between hypertension (high blood pressure) and consumption of sugar. Past studies have indicated that the consumption of fruits...
-
Suppose there is a medical diagnostic test for a disease. The sensitivity of the test is .95 . This means that if a person has the disease, the probability that the test gives a positive response is...
-
Let \(Y\) have the Poisson \((=2)\) distribution. (a) Calculate \(P(Y=2)\). (b) Calculate \(P\left(\begin{array}{ll}Y & 2\end{array} ight)\). (c) Calculate \(P(1 \quad Y <4)\).
-
Environmental laws for vinyl upholstery companies in India and Brazil? Intellectual property laws relating for vinyl upholstery companies in India and Brazil?
-
Consider the reaction of acetic acid in water CH 3 CO 2 H(aq) + H 2 O(l) CH3CO 22 (aq) + H 3 O + (aq) where Ka 5 1.8 3 1025. a. Which two bases are competing for the proton? b. Which is the stronger...
-
Considering the following SDE for the spot rate: drt = ( rt)dt + rtdWt (19.41) Using the following set of parameters: r0 = 0.03 (19.42) = 1.5 (19.43) = 0.06 (19.44) = 0.25 (19.45) T = 1 (19.46)...
-
We consider the random process St, which plays a fundamental role in Black-Scholes analysis: where Wt is a Wiener process with W0 = 0, is a "trend" factor, and (Wt Ws) N (0, (t s)) which says...
-
Consider the mean-reverting process dSt = ( St)dt + StdWt. Create a time discretization of = 1/252 and assume that the appropriate monthly model parameters are: = 0.75 = 0.35 S0 = 40 Consider the...
-
Find the relationship of the eight SU(3) operators \(T_{ \pm}, V_{ \pm}, U_{ \pm}, T_{3}\), and \(Y\) defined in Eqs. (8.2) and (8.7)-(8.8), and the nine oscillator operators \(\left(A_{i}^{j}...
-
Verify that the set of matrices (5.14) is closed under ordinary matrix multiplication. Data from Eq. 5.14 T(oc)= = 629 > - (+19) TOO) = (721) TO) = ( ). T(oa)= T(b) TO) -(11) T(4-(11) TO=(9) T(C3)= =
-
(a) Show that the most general \(2 \times 2\) unitary matrix with unit determinant can be parameterized as in Eqs. (6.76) and (6.77). (b) Take the group identity element \(U(1,0,0,0)\) to correspond...
Study smarter with the SolutionInn App