Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
CS401 Computer Architecture and Assembly Language Programming Last Date 11 Dec 2014
#1


CS401 Computer Architecture and Assembly Language Programming No-1 Assignment Last Date 11 Dec 2014



Computer Architecture and Assembly Language Programming (CS401) Assignment # 02 (Graded) December 11, 2014

1) You should concern recommended books to clarify your concepts as handouts are not sufficient.

2) You are supposed to submit your assignment in .doc format. Any other formats like scan images, PDF, zip, rar, bmp etc will not be accepted.



Topic Covered:

Branching Techniques.
Bit Manipulation.
Subroutines.


Question Statement:



Write a complete assembly language code having two subroutines:

One will be named as Fibonacci_series used to generate a Fibonacci series of first 10 elements.
Second will be named as Fibonacci_sum and will find the sum of all elements in a generated Fibonacci series/array.


Hint: Make a series/array named as Fibonacci_array and a lable named as fib_sum.

Fibonacci_array will contain the generated Fibonacci sequence elements, while fib_sum is used to store the sum of an array (Fibonacci array).



You can define Fibonacci array as:



Fibonacci_array: DW 0 1

Fib_sum = Fibonacci (0) + Fibonacci (1) + … + Fibonacci (10).



Fibonacci function is defined as follows:

Fibonacci (0) = 0

Fibonacci (1) = 1

Fibonacci (n) = Fibonacci (n-1) + Fibonacci (n-2)



You have to calculate till Fibonacci (10).



You have to attach a final snapshot of your debugger showing the Fibonacci series and Fibonacci sum in Data segment (DS)

0300-9520262
Get solution in 24 hour
|cpmputer & internetConfusedmileys81:[SIZE="4"][SIZE="3"]....[/SIZE][/SIZE]
Reply
#2
e code given below will print 123456789 this is a loop
global _start ;must be declared for using gcc
_start: ;tell linker entry point
mov ecx,10
mov eax, '1'

l1:
mov [num], eax
mov eax, 4
mov ebx, 1
push ecx
mov ecx, num
mov edx, 1
int 0x80
mov eax, [num]
sub eax, '0'
inc eax
add eax, '0'
pop ecx
loop l1
mov eax,1 ;system call number (sys_exit)
int 0x80 ;call kernel
section .bss
num resb 1

0300-9520262
Get solution in 24 hour
|cpmputer & internetConfusedmileys81:[SIZE="4"][SIZE="3"]....[/SIZE][/SIZE]
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Assignment solution eng 301 due date 20 may 2015 rumesa khan 3 4,540 05-20-2015, 01:34 AM
Last Post: Xpert
  cs401 assignment no 1 spring may 2015 solution for idea Xpert 0 4,379 05-15-2015, 03:45 AM
Last Post: Xpert
  vu eng301 first assignment spring 2015 due date 22 may Xpert 0 2,815 05-15-2015, 03:34 AM
Last Post: Xpert
  Bus Ticket Reservation System SRS CS619 Final Software Project Semester Fall 2014 Vuhelper 6 5,135 01-13-2015, 04:46 AM
Last Post: Xpert
  CS710 Mobile and Pervasive Computing Assignment No. 2 Fall 2014 Vuhelper 0 2,612 12-23-2014, 02:41 PM
Last Post: Vuhelper
  MTH301 - Calculus II Assignment No. 02 Solution and Discussion Fall 2014 Vuhelper 0 2,788 12-17-2014, 09:34 PM
Last Post: Vuhelper
  CS601 Assignment No. 2 Close Date is 15th December 2014 Vuhelper 3 3,645 12-15-2014, 09:53 PM
Last Post: Vuhelper
  ENG201 Business & Technical English Assignment No. 02 Due Date Dec 15, 2014 education-2014 2 3,311 12-15-2014, 08:30 PM
Last Post: Vuhelper
  IT430 - E-Commerce Assignments No. 2 Solution and Discussion Close Date Dec 15, 2014 Entboy 2 2,817 12-15-2014, 04:29 PM
Last Post: Vuhelper
  STA406 Assignment Solution Fall 2014 (Total Marks15) 15th December 2014 Vuhelper 0 2,264 12-15-2014, 04:25 PM
Last Post: Vuhelper

Forum Jump:


Users browsing this thread: 2 Guest(s)