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
VMariaS [17]
4 years ago
10

Write a program that turns a 32-bit numeric value (e.g., 0xFFFFh) and converts it to a byte array such that it can be printed to

the screen using a system call method. A loop is necessary for converting the numeric value to ASCII for output. Again, use a system call (e.g., int 80h) to print the value to the console (see "Course Material" -> Examples). Calling external functions (e.g. printf) is not allowed.
Computers and Technology
1 answer:
Evgesh-ka [11]4 years ago
3 0

Answer:

The program is written below,

.386

.MODEL FLAT, stdcall

.STACK 4096

GetStdHandle PROTO, nStdHandle:DWORD

WriteConsoleA PROTO,

hConsoleOutput:DWORD, ; output handle

lpBuffer:PTR BYTE, ; pointer to buffer

nNumberOfCharsToWrite:DWORD, ; size of buffer

lpNumberOfCharsWritten:PTR DWORD, ; num bytes written

lpReserved:DWORD ; not used (NULL)

ExitProcess PROTO, dwExitCode:DWORD

.data

bytesWritten DWORD 0 ; for WriteConsoleA

stdHandle DWORD 0 ; for WriteConsoleA

s1 BYTE "Hello Universe", 13, 10, 0

lenS1 = ($ - s1)

.code

_main PROC

print:

; get STDOUT handle

push -11 ; request STD_OUTPUT_HANDLE (-11)

call GetStdHandle ; call WinAPI to get console handle

mov stdHandle, eax ; save stdHandle

push 0 ; reserved, push NULL

push OFFSET bytesWritten ; bytes written

mov eax, lenS1

push eax ; bytes to write

push OFFSET s1 ; string address

push stdHandle ; STD_OUPUT_HANDLE

call WriteConsoleA ; call win api to write text to console

done:

INVOKE ExitProcess, 0

_main ENDP

END

You might be interested in
which of these describes a property of all elements A. all elements have six electrons B. all elements are pure substances C. al
sergiy2304 [10]
Im guessing the answer would either B or C
3 0
3 years ago
The ____ is the ranking executive on-site when the crisis or emergency arises, who is authorized to initiate the CM plan.
aleksklad [387]

The answer is the Executive-in charge

The concept of an Executive-in charge came from the military’s chain of command. A chain of command ranges from a supervisor to the top executive of the organization. When a crisis arises, it is possible that one or more of the senior top managers may not be available for consultations because of the travel-intensive positions.






7 0
3 years ago
Read 2 more answers
Which word did alexander graham bell want adopted as a telephone greeting instead of hello.
Alik [6]

Answer:

I believe it was Ahoy.

Explanation:

I could be wrong though.

7 0
3 years ago
Read 2 more answers
Match each feature of the E publishing as an advantage a disadvantage a threat or an opportunity
natta225 [31]

Answer:

E-publishing is also known as digital publishing or online publishing.It means to publish the content in electronic form.It is growing rapidly.It consist digital publication of e-books,digital magazines that can be read on a screen.

<u>Explanation:</u>E-publishing is very convenient.We do not have to keep  large number of books on the shelves.E-books are best during travelling because we need not to carry heavy luggage of books.E-books are cheaper than paperbacks.

E-publishing can allow the authors  to reach large number of readers.Electronic contents are very well updated.Electronic books are environment friendly.It saves wastage of papers and hence cutting of trees.

Besides above advantages there are some disadvantages of E-publishing:

There are more responsibilities in E-publishing.Chances of copyright infringement can be there.

Profits are very low in case of e-publishing.It is not easy to earn money through this method.

Quality of printed books is much better than e-books.

So we can say that e-publishing has it's own advantages and disadvantages.

3 0
4 years ago
Use this illustration to answer the question.
Mademuasel [1]

Answer:

very high voltage hope this helps

Explanation:

4 0
3 years ago
Other questions:
  • Suppose that the splits at every level of quicksort are in the proportion 1 − α to α where 0 &lt; α ≤ 1/2 is a constant. Show th
    6·1 answer
  • Problem 1 Calculating the tip when you go to a restaurant is not difficult, but your restaurant wants to suggest a tip according
    6·1 answer
  • ______ includes websites that encourage interaction and connection among people, businesses, and organizations.
    9·2 answers
  • What do economists call a decline in the real GDP combined with a temporary rise in price level?
    8·2 answers
  • 3. Wi-fi connections have limited range of :
    9·1 answer
  • When you purchase donuts, they come in boxes of 12, so 24 donuts take 2 boxes. All donuts need to be in a box, so if you buy 13
    10·1 answer
  • The concept of taking traffic that’s all aimed at the same node and delivering it to the proper receiving service is known as
    8·1 answer
  • 1. Write the full forms of the following.
    8·2 answers
  • What is the output of the following code snippet? int i = 1; while (i != 9) { System.out.print(i + " "); i++; if (i == 9) { Syst
    11·1 answer
  • Which discipline focuses on the design of computer hardware?
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!