Program analysis , Electrical Engineering

Program Analysis

We have to find the greater of two given  number. We  can store the given  numbers  in two  different  registers ( suppose register A and B). Then we will compare the  contents  of  register B with  the contents of accumulator A. If the contents A are greater than B  Both  CY and Z  flag is reset.  If  the contents of A are equal  to B, Z  flag is  set and CY  flag is  reset. Here we assume for simplicity  of the  program that the  given  numbers are not  equal   then only carry flag can decide that which  number is greater. F carry flag  is set  the content of accumulator  A are less  than the contents  of B otherwise  the contents  of B  are greater  than the contents  of accumulator A.

Flow chart   : it is better  to draw  the flow  chart before  writing the program.

Posted Date: 4/5/2013 1:21:33 AM | Location : United States







Related Discussions:- Program analysis , Assignment Help, Ask Question on Program analysis , Get Answer, Expert's Help, Program analysis Discussions

Write discussion on Program analysis
Your posts are moderated
Related Questions
Q. Consider a conducting loop of length l and width w, as shown in Figure, rotated about its axis (shown by the broken line) at a speed of ωm rad/s under the influence of a magneti

what is power factor of generator at overexcitation

how to connect some DG together?

Q. For the capacitor shown in Figure connected to a voltage source, sketch i(t) and w(t).

Background Information Electrical machines usually consist of copper windings on steel cores, and their AC resistance is greater than their DC resistance. The power loss has


You will manufacture composite beams using an epoxy matrix (West Systems 105 epoxy resin + West Systems 206 slow hardener) and one of the following reinforcements:  1.  Unidirec

NOP No Operation Instruction No operation  is performed  when this  instruction is executed. The instruction format is             NOP All  registers and flags  re

Hexadecimal  to Binary Conversion Conversion from  hexadecimal  to binary  is the  reverse  of this  process. Express each  hexadecimal  digit  in four bit  binary  equivalent

Write explanatory notes on  Microprocessor development system. Microprocessor development system : Computer systems have undergone several changes recently. Machines which