Giter Site home page Giter Site logo

fardinanam / assembly-8086-codes Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 3.0 500 KB

Practice problems and solutions of the assignments offered in CSE316 course in BUET.

Assembly 100.00%
8086-emulator assembly-language-programming binary-search insertion-sort selection-sort

assembly-8086-codes's Introduction

Assembly-8086 Assingments and Practices

Insersion Sort and Binary Search

Problem Specifications

In this sessional you will implement insertion sort and binary search algorithm in assembly language programming. You will take n integers as inputs from a user, sort them and display the sorted array. Next you will take another integer as input from the user and search it in the sorted array using binary search algorithm and display its index in the sorted array if it exists (Assume that indices start from 1). In a nutshell, you have to implement the following algorithmic steps.

  1. Take an integer n from the user.
  2. Go to Step 10 if n <=0
  3. Take n integers from the user.
  4. Sort them using insertion sort.
  5. Display the sorted array.
  6. Take an integer x from the user.
  7. Use binary search to find x’s index in the sorted array. Display the index if found, otherwise print ‘NOT FOUND’.
  8. For another search in the same array go to Step 6.
  9. Go to Step 1.
  10. End

Note: You can assume any form of number to be in the range of signed 16 bit register.

Convert Any Based Number to Binary

Problem Specifications

Take a base value as input from the user. Then take an input N in the base value of given base. Convert the given number to binary and display.
Note: You can assume any form of number to be in the range of signed 16 bit register.

Calculating Number of Faulty Numbers

Problem Specifications

A faulty number is one for which the sum of its proper divisors is greater than the number itself. The proper divisors of a number are all the divisors except 1 and the number itself. For example, 12 is a faulty number because the sum of the proper divisors is 2+3+4+5=15 which is greater than 12. Write a program to take an integer number N as input and output the number of faulty numbers between 1 and N
Note: You can assume any form of number to be in the range of signed 16 bit register.

Selection Sort in Descending Order

Problem Specifications

Take N integers as inputs from the user. Sort them in descending order using selection sort and display the sorted array for every step of the selection sort operation. Finally print the sorted array.
Note: You can assume any form of number to be in the range of signed 16 bit register.

assembly-8086-codes's People

Contributors

fardinanam avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.