1 / 11

Assembly Language Programming - Examples

Learn simple assembly language programming with examples that cover topics like loops, arrays, strings, and more.

Download Presentation

Assembly Language Programming - Examples

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. EE3541 Introduction to Microprocessors Assembly LanguageProgramming …… example Medien Zeghid EE Department PRINCE SATTAM BIN ABDULAZIZ UNIVERSITY COLEGE OF ENGINEERING AT WADI ADDAWASER

  2. Assembly Language Programming …example 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. Write the equivalent 8086 code for ax=4; bx=7; while (ax >= 8) { bx=bx+1, if (bx==9) then break; else continue; } bx=bx+2;

  3. Assembly Language Programming …example Write a program in Assembly Language which display your name after the word Hello Output of Program: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  4. Assembly Language Programming …example Write a program in Assembly Language which takes a number as an input ( from 1 to 9) and display your name that much amount of times on next line. (Use for loop). Output of Program: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  5. Assembly Language Programming …example Write a program in Assembly Language which input one of the Decimal Numbers 1-8 and display the next number on the next line. Output of Program: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  6. Assembly Language Programming …example Write a program in Assembly Language to find the maximum number from an array of ten numbers. 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. array= max=50

  7. Assembly Language Programming …example Write a program in Assembly Language to find the number of times letter ‘e’ exist in the string ‘exercise’, Store the count at memory ans. 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  8. Assembly Language Programming …example Write a program in Assembly Language to reverse the given string. 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  9. Assembly Language Programming …example Write an assembly program that can display the following figure. * ** *** **** ***** 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  10. Assembly Language Programming …example Write an assembly program that can read a character and integer n. This program has to print out n characters beginning from the read character. For example if the read character was “c” and the integer number was 5, the program has to print: c d e f g 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

  11. Assembly Language Programming …example Translate to assembly program the following pseudo-code algorithm. Write "Enter two integer values" Read first, second IF (first < second) Write first, second ELSE Write second, first End if 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

More Related