Stack structure for unsigned integers

Assignment Help Assembly Language
Reference no: EM1395974

Use MARIE's ISA program a stack structure for unsigned integers.

Stack

You should write three subroutines for the stack: peek, push, and pop. The location of the stack is between locations 600 and 700.

  • push function should take a parameter and push it into the top of the stack. You should move all the items currently in the stack down one position. If the stack is full, your program should return -1. This is the stack overflow error.
  • pop function should return a parameter and it is the value on the top of the stack. You should move all the items currently in the stack up one position. If the stack is empty befor the pop, you should return a -1.
  • peek function will return the value of the top of the stack. No action is needed on the data of the stack. If the stack is empty, you should return -1.

It will be helpful if you use a variable to keep a record of how many data are currently in the stack.

Write a program to push 10 items into your stack, and pop them out.

Reference no: EM1395974

Questions Cloud

Age-adjusted percent smoking-time : The estimated age-adjusted percent of persons 18 years of age and over who smoke cigarettes are shown below for females and males for selected years.
Corresponds to a confidence interval : Assume that in a hypothesis test with null hypothesis Ho: μ = 14.0 at a= 0.05, that a value of 13.0 for the sample mean results in the null hypothesis not being rejected. That corresponds to a confidence interval result of:
How is dna generally packaged inside organelles : How is DNA generally packaged inside organelles? DNA is packaged in membrane-bound vesicles within the organelles. DNA is anchored to the inner membrane of the organelle.
Illustrate direct also indirect approach for your message : Industry policy dictates which you must provide this information in writing. Illustrate what questions you should consider among the direct also indirect approach for your message.
Stack structure for unsigned integers : Write a program to push 10 items into your stack, and pop them out - Use MARIE's ISA program a stack structure for unsigned integers.
Equation of regression line and correlations : U.S. News & World Report publishes the average starting salary and the average GMAT score for MBA graduates at each of the top 80 ranked schools in the country.
Describe the major difference between mitosis and meiosis : Describe each of these problems. Which areas worldwide are suffering the most from these problems.
Compute a p-value for the hypothesis test : test the hypothesis that the intake of linoleic acid in this group is lower than that of the general population. Also, compute a p-value for the hypothesis test.
Explain how many units should be purchased for each : Prepare a merchandise purchases budget showing Explain how many units should be purchased for each of the months April, May, also June. Prepare a schedule of expected cash collections for each of the months April, May, also June.

Reviews

Write a Review

Assembly Language Questions & Answers

  Write an assembly language program

Write an assembly language program for encrypting alphabates of a string

  Write assembly program print binary representation-integers

Write the assembly program called hw6_ex1, stored in file hw6_ex1.asm. This program must prompt user to enter signed 32-bit integer. Program must print out binary representation of the integer.

  Write an assembly program

Prepare an Assembly program that reads in a number of cents.

  Write assembly program-find right admission price to movie

Write the Assembly program to find correct admission price to movie. Price of admission to a movie is $7 for kids (under 12) and $9 for adults.

  Program in assebly language to solve first degree equations

Create the program on Assebly language which can solve First Degree Equations in form of Ax + B = 0. Coefficients of equation must be entered from keyboard.

  Build an 8088 assembler

In this project, you will build an 8088 assembler. The job of your assembler is to turn 8088 assembly code (i.e., the 8086 assembly code language) into 8088 machine code that executes in an DOS emulator.

  Integral square root of an input number

Write a short assembly program that computes the integral square root of an input number and In this problem you will write a program that will compute the first 20 numbers in the Fibonacci sequence.

  Create a assembly language subroutine

Create a assembly language subroutine MULSUM that takes an array named A containing n bytes of positive numbers, and fills two arrays, array B containing n words and array C containing n long words

  Write mips assembly program to read two non-negative numbers

Write MIPS assembly program to repeatedly read two non-negative integers and print integer product and quotient without using multiplication and division instructions.

  Allot op-codes and add microcode to microprogram

Allot op-codes and add microcode to microprogram of Mic-1 to implement following instructions which are then included with IJVM instruction set.

  Analog measurements

Prepare an assembly program for the correctly measures the wind direction

  Design a simple digital clock

Design a simple digital clock

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd