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
MrRa [10]
3 years ago
14

Hello, this is a 2 part question for my beginning assembly class. Thank you in advance for your help

Computers and Technology
1 answer:
madam [21]3 years ago
3 0

Answer:

Complete code is given below:

Explanation:

INCLUDE Irvine32.inc

.data

msgMenu BYTE "---- Boolean Calculator ----", 0dh,0ah

BYTE 0dh,0ah

BYTE "1. x AND y"     ,0dh,0ah

BYTE "2. x OR y"      ,0dh,0ah

BYTE "3. NOT x"       ,0dh,0ah

BYTE "4. x XOR y"     ,0dh,0ah

BYTE "5. Exit program",0

msgAND      BYTE "Boolean AND",0

msgOR       BYTE "Boolean OR",0

msgNOT      BYTE "Boolean NOT",0

msgXOR      BYTE "Boolean XOR",0

msgOperand1 BYTE "Input the first 32-bit hexadecimal operand: ",0

msgOperand2 BYTE "Input the second 32-bit hexadecimal operand: ",0

msgResult   BYTE "The 32-bit hexadecimal result is:            ",0

caseTable   BYTE '1'     # lookup value

DWORD _AND_op        # address of the procedure

EntrySize = ($ - caseTable )

   BYTE '2'

   DWORD _OR_op

   BYTE '3'

   DWORD _NOT_op

   BYTE '4'

   DWORD _XOR_op

   BYTE '5'

   DWORD _ExitProgram

NumberOfEntries=($ - caseTable)/EntrySize

.code

main08stub PROC

   call Clrscr

Menu:

   mov edx, OFFSET msgMenu # menu choices

   call WriteString

   call Crlf

L1: call ReadChar

   cmp al, '5' # is selection valid (1-5)?

   ja L1   # if above 5, go back

   cmp al, '1'

   jb L1   # if below 1, go back

   call Crlf

   call **BLANK**

   jc quit # if CF = 1 exit

   call Crlf

   jmp Menu    # display menu again

quit: exit

main08stub ENDP

#----------------------------------------

**BLANK** PROC

#

# It selects a procedure from the case table

# Receives: AL = number of procedure

# Returns: nothing

#-----------------------------------

   ret

**BLANK** ENDP

#------------------------------------------------

_AND_op PROC

#

# Performs a boolean AND operation

# Receives: Nothing

# Returns: Nothing

#------------------------------------------------

   ret

_AND_op ENDP

#------------------------------------------------

_OR_op PROC

#

# Performs a boolean OR operation

# Receives: Nothing

# Returns: Nothing

#------------------------------------------------

   ret

_OR_op ENDP

#------------------------------------------------

_NOT_op PROC

#

# Performs a boolean NOT operation.

# Receives: Nothing

# Returns: Nothing

#------------------------------------------------

   ret

_NOT_op ENDP

#------------------------------------------------

_XOR_op PROC

#

#

# Performs an Exclusive-OR operation

# Receives: Nothing

# Returns: Nothing

#------------------------------------------------

   ret

_XOR_op ENDP

#------------------------------------------------

_ExitProgram PROC

#

# Receives: Nothing

# Returns: Sets CF = 1 to signal end of program

#------------------------------------------------

   ret

_ExitProgram ENDP

END main08stub

You might be interested in
What is the distance from the end of the pin to the center of the hole?
Lemur [1.5K]

Answer:

Roughly 7/8 on the pinhole, roughly 2-1/4" from the pinhole to end of the adapter.

Explanation:

8 0
1 year ago
Write a menu-based program in C++ for an input restricted dequeue using Linked List consist of
Natali5045456 [20]

Answer:

C++ With Examples

— Input-restricted Deque: In input-restricted, deletion can be done from ... getLast: Retrieves the last item in the queue. ... Now, we insert element 3 at the rear.

8 0
2 years ago
This question refers to a standard deck of playing cards. If you are unfamiliar with playing cards, there is an explanation in P
Norma-Jean [14]

Answer:

Explanation:

Number of ways to select 10 girls in 35C₁₀

Number of ways to select 10 boys in 35C₁₀

Total Number of ways to select is 35C₁₀ x 35C₁₀

4 0
3 years ago
Read 2 more answers
True or false: you should reuse passwords on multiple websites because it will help you remember those passwords
Fudgin [204]

Answer: False

Explanation: Even though you can remember it is not really good because some hackers can track you passwords through those websites and could hack your account.

3 0
2 years ago
Read 2 more answers
3. Do some Internet research on the use of VLANs in hospitals. Summarize the benefits of using VLANs in hospitals and identify e
motikmotik

VLAN refers to Virtual Local Area Network. It is a subnetwork that can group together collection of devices on separate physical Local Area Networks. VLANs allow network administrators to group hosts together even if the hosts are not directly connected to the same network switch.

Considering the large number of departments in hospitals, with each departments having functions different from the others, Virtual LANs allows various users(the departments) to be grouped together according to their networking needs, regardless of their actual physical locations. Subdividing the LAN into smaller segments, or VLANs, increases overall reliability, security, and performance, and makes the network easier to maintain.

Because of the largeness of St. Luke's hospitals and their mission of delivering highly reliable and feature-rich advanced network solutions, virtual LAN will help to provide a resilient and scalable network solution within the hospital's budget.

St. Luke should implement virtual LAN that can produce a higher bandwidth with lower-cost, a longer-term model based on servers, networking products and homogenous network components to deliver centralized management of computing across the hospital network.

5 0
3 years ago
Read 2 more answers
Other questions:
  • (Drag each tile to the correct box)While surfing online, Patricia first checks her email and reads the latest messages. She then
    8·1 answer
  • The global network that links millions of computers is the
    9·2 answers
  • John would like to move from the city into the suburbs and has been saving up a large down payment for a home. Which is the most
    7·1 answer
  • Traffic that is encrypted will typically pass by an intrusion prevention system untouched.a. Trueb. False
    10·1 answer
  • Consider the following skeletal C program: void fun1(void); /* prototype */ void fun2(void); /* prototype */ void fun3(void); /*
    11·1 answer
  • What is something that can be done to help stop teen teen crashes
    8·1 answer
  • Which screen should be open to customize or personalize a desktop background?
    15·2 answers
  • To indent an entire paragraph or list you should:
    9·1 answer
  • Where is the third vanishing point in the three point perspective
    8·1 answer
  • How dose computers it use the information to solve problems
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!