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
Vitek1552 [10]
4 years ago
14

Use a loop with indirect or indexed addressing to reverse the elements of the integer array in place. Do not copy the elements t

o any other array. Use the SIZEOF, TYPEOF, and LENGHTOF operators to make the program as flexible as possible if the array size and type should be changed in the future. Optionally, you may display the modified array by calling the DumpMem method from the Irvine32 library.
Computers and Technology
1 answer:
finlep [7]4 years ago
4 0

Answer:

INCLUDE Irvine32.inc

.data

      ;declare and initialize an array

      array1 DWORD 10d,20d,30d,40d,50d,60d,70d,80d,90d

.code

main PROC

      ;assign esi value as 0

      mov esi,0

      ;find the size of array

      mov edi, (SIZEOF array1-TYPE array1)

      ;find the length of the array

      ;divide the length by 2 and assign to ecx

      mov ecx, LENGTHOF array1/2

;iterate a loop to reverse the array elements

L1:

      ;move the value of array at esi

      mov eax, array1[esi]

      ;exchange the values eax and value of array at edi

      xchg eax, array1[edi]

      ;move the eax value into the array at esi

      mov array1[esi], eax

      ;increment the value of esi

      add esi, TYPE array1

      ;decrement the value of edi

      sub edi, TYPE array1

      loop L1

;The below code is used to print

;the values of array after reversed.

      ;get the length of the array

      mov ecx, LENGTHOF array1

      ;get the address

      mov esi, OFFSET array1

L2:

      mov eax, [esi]

      ;print the value use either WriteDec or DumpMems

      ;call WriteDec

      ;call crlf

      call DumpMem

      ;increment the esi value

      add esi, TYPE array1

      LOOP L2

exit

main ENDP

END main

You might be interested in
How to download music to your mp3 player off computer
skelet666 [1.2K]
For free or for money cuz for free u would do ot on ur mp3 and money i would yse apple music
3 0
3 years ago
Zadanie nr 1
Gennadij [26K]

Answer:

Explanation:

Rezonans, Obiekt bez wibracji ma tendencję do robienia tego z określoną częstotliwością zwaną naturalną lub rezonansową częstotliwością obiektu. (Ta częstotliwość zależy od wielkości, kształtu i składu przedmiotu). Taki przedmiot będzie silnie wibrował, gdy zostanie poddany wibracjom lub regularnym impulsom o częstotliwości równej lub bardzo zbliżonej do swojej częstotliwości naturalnej. Zjawisko to nazywa się rezonansem. Dzięki rezonansowi stosunkowo słaba wibracja w jednym obiekcie może powodować silne wibracje w innym. Analogicznie termin rezonans jest również używany do opisania zjawiska, w którym oscylujący prąd elektryczny jest wzmacniany sygnałem elektrycznym o określonej częstotliwości.

Przykład rezonansu zapewnia silnik, który powoduje wibracje mebla w innej części tego samego domu. Drgania te występują, ponieważ częstotliwość naturalna mebli jest równa częstotliwości drgań ustawianych przez silnik. Mówi się, że meble rezonują z silnikiem. Rezonans można również zaobserwować w samochodzie, gdy pewna popielniczka Partan, na przykład wibruje, gdy samochód jedzie z określoną prędkością. Popielniczka rezonuje z wibracjami silnika przy tej prędkości.

Rezonans mechaniczny może wytwarzać wibracje wystarczająco silne, aby zniszczyć obiekt, w którym występują. Na przykład żołnierze maszerujący nad mostem mogą wytwarzać ekstremalne wibracje z częstotliwością naturalną mostu i roztrzaskiwać go na części. Z tego powodu żołnierze przebijają się, by przejść przez most. W 1940 r. Podmuchy wiatru w Puget Sound Narrows w Tacoma w stanie Waszyngton spowodowały, że most wiszący wibruje z naturalną częstotliwością i most zawalił się.

W muzyce rezonans służy do zwiększenia intensywności (głośności) dźwięku. Na przykład stosunkowo słabe wibracje wytwarzane na końcu rurki organowej powodują, że kolumna powietrza w rurze wibruje w rezonansie, znacznie zwiększając głośność dźwięku. Zasada ta dotyczy także głosu ludzkiego, w którym wibracje strun głosowych są wzmacniane przez wibracje rezonansowe w kanałach ustnych i nosowych.

Rezonans elektryczny służy do strojenia radiotelefonów i telewizorów. Strojenie polega na ustanowieniu obwodu o częstotliwości rezonansowej równej przydzielonej częstotliwości żądanej stacji.

6 0
3 years ago
18. The push rod connects to the _______, which is designed to pivot back and forth to open and close the valve.
spin [16.1K]
In an overhead valve engine, pushrods connect to A. rocker arm which pivots and opens valves
6 0
3 years ago
Read 2 more answers
="Jack"&"$"&"Jill". What will be the output of this formula?​
natita [175]
I’m so confused on this but hey here’s this

3 0
3 years ago
If your current directory is /usr/david, the command cd / changes your current directory to
Veseljchak [2.6K]
The command "cd /" changes your current directory to the root directory.
6 0
3 years ago
Other questions:
  • A viral video is one that can infect your computer with malware. <br> a. True <br> b. False
    6·1 answer
  • You listened to a song on your computer. did you use hardware or software? explain.
    15·1 answer
  • Match these items. 1 . Naturalization Act stated that a foreigner had to live in the United States fourteen years to become a ci
    5·1 answer
  • What effect does the interconnectedness of modern media have on society?
    14·2 answers
  • Determine the exact output of the code $str = "The quick brown fox jumps over the the lazy dog"; echo strpos($str, 'fox');
    6·1 answer
  • Since the 1960s, there have been five major generations, or cycles, of computing. Which represents those generations in order?
    15·1 answer
  • Use the drop-down menus to complete the steps to share a presentation through OneDrive.
    6·1 answer
  • Read the ages of three people and find the average. Display the result.
    10·1 answer
  • Help PLEASE ILL MARK as brainlest
    11·1 answer
  • St. CHarles school's music community is organizing a fundraiser. They want to create a simple but attractive website. However, t
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!