Latest Activity In Study Groups

Join Your Study Groups

VU Past Papers, MCQs and More

We non-commercial site working hard since 2009 to facilitate learning Read More. We can't keep up without your support. Donate.


CS401 Assignment 01 Spring 2021 Solution / Discussion Due Date: 18-05-2021

  1. Write an assembly language program to add all the digits of your VUID and store the sum in memory.
  • Store all the digits of VUID in the memory.
  • Use loop and jumps to add the digits.
  • If the number is 0, then the program should not add that digit and move to the next digit.
  • Store the sum in another variable.

Note: Make it sure to use your own VUID, otherwise zero marks will be awarded.

Submission details:

Following are required in a single MS-Word document.

  • Assembly language program.
  • Screenshot of AFD debugger at the start of program.
  • Screenshot of AFD debugger showing the final values.

 

Views: 1180

Replies to This Discussion

Stay touched with this discussion, Solution idea will be uploaded as soon as possible in replies here before the due date.

cs401 Assignment 1 solution spring 2021

[org 0x0100]

jmp start

start:

             mov bx,0

             mov cx ,9

             mov ax,0

             mov si,0

12:

             cmp[num1+bx],si

             je next

             add ax[num1+bx]

next:

             add bx,2

             sub cx,1

             cmp cx,0

             jnz 12

            mov[num2] ,ax

            mov ax, 0x4c00

            num1:dw 2,2,0,3,6,9,3,3,5

            num2: dw 0

CS401 Assignment 1 Solution Spring 2021 || 100% Correct Solution || Assignment Coding

CS401 Assignment No.1 Spring 2021 with Run 100% Correct Complete Solution By Abid Farooq Bhutta.

CS401 Assignment No.1 Spring 2021 100% Correct Complete Solution By Abid Farooq Bhutta. CS401 Assignment 1 Complete Correct Solution Solved 2021 || Spring 2021 CS401 Solution Assignment no.1 2021 || Complete Correct Spring 2021 Solved. CS401 Assignment 1 Complete Solution Spring 2021, CS401 Assignment 1 Complete Solution, CS401 Assignment 1, CS401 , CS401 Assignment 1 solution, CS401 assignment Spring 2021, CS401 assignment solution Spring 2021, CS401 assignment, Assignment 1 CS401 solution, solution CS401 Assignment 1, CS401 Assignment 1 solution 2021, CS401 assignment solution 2021, CS401 Assignment 1, CS401 Assignment 1 solution Spring 2021, CS401 Assignment no 1 solution Spring 2021, CS401 Assignment no 1 solution 2021, CS401 1rd assignment solution 2021, CS401 1rd assignment solution, CS401 1st assignment solution Spring 2021,assignment solution Spring 2021, # CS401 # CS401assignment1solution2021

CS401 Assignment 1 Solution 2021 Spring:

Assignment No. 1

Semester Spring :2021

#CS401 Assignment 1 Solution 2021 Spring

Solution :

[org 0x0100]

jmp start

start:

             mov bx,0

             mov cx ,9

             mov ax,0

             mov si,0

12:

             cmp[num1+bx],si

             je next

             add ax[num1+bx]

next:

             add bx,2

             sub cx,1

             cmp cx,0

             jnz 12

            mov[num2] ,ax

            mov ax, 0x4c00

            num1:dw 2,2,0,3,6,9,3,3,5

            num2: dw

CS401 Assignment 1 Solution 2021 Spring

Assignment No. 1

Semester Spring :2021

Capture.PNG

sir yeh aa raha hai

apnay kr li to plz mujhy send kr dyn gya kiya 

sir yeh adha solution hai. dosbox, masm and afd pe kaam karna abhi baki hai

CS 401 assembly language assignment 1 solution spring 2021.

 

Cs401 Assignment1 Solution

Q. Write a program to add all digit of vu id and store the sum in memory

· Store all of vu id in memory
· Use loop and jumps to add digits
· If the number is 0 then program should not add digit
· Store the sum in another variable

Code:

[org 0x0100]

Jmp start

Start:
Mov bx,0
Mov cx,9
Mov ax,0
Mov si,0

L2:
Cmp [num1+bx],si
Je next
Add ax,[num1+bx]

Next:
Add bx,2
Sub cx,1
Cmp cx,0
Jnz L2

Mov [num2],ax
Mov ax,4ch
Int 21h
Num1 dw 2,9,4,2,3,4,5,0,2
Num2 dw,0

RSS

Looking For Something? Search Below

VIP Member Badge & Others

How to Get This Badge at Your Profile DP

------------------------------------

Management: Admins ::: Moderators

Other Awards Badges List Moderators Group

Latest Activity

Ammara Sabir posted a status
"Jb muhabat hi nhi drmyan tu ;;;;;;;;;;;: wu rothein kya @@@ or hm mnaein kya"
39 minutes ago
Ammara Sabir liked Honey Chaudhary's discussion Sabit to kar
49 minutes ago
Ammara Sabir liked + ♥ Haniya khan's discussion (Bal-e-Jibril)
1 hour ago
Ammara Sabir liked Honey Chaudhary's discussion شور کروں گا اور نہ کچھ بھی بولوں گا
1 hour ago
Ammara Sabir liked + ♥ Haniya khan's discussion (Bal-e-Jibril)
1 hour ago
Ammara Sabir liked ♥Sυɠαɾ Gҽɳιυʂ♥'s discussion just feel
1 hour ago
+ ♥ Haniya khan liked ♥Sυɠαɾ Gҽɳιυʂ♥'s discussion just feel
5 hours ago
+ ♥ Haniya khan replied to ♥Sυɠαɾ Gҽɳιυʂ♥'s discussion just feel
5 hours ago

© 2021   Created by + M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service