The basic algorithm for a bubble sort requires a boolean indicator. As the program cycles through the array to be sorted, it steps by one and compares n and n+1. If n+1 is greater than n, then they are swapped, the boolean indicator is set to false and the comparator increments by one. Once the comparator makes a complete cycle through without the indicator flagging to false, the array is sorted.
Program for bubble sort for integer array:
#include<stdio.h>
void main()
{
int i,j,k,temp;
printf("Enter the length of array:");
scanf("%d",&i);
int a[i];//Array declaration
printf("Enter the no:\n");
for(j=0;j<i;j++)//data insertion in array
{
scanf("%d"&a[j]);
}
//bubble sort
for(k=0;k<(i-1);k++)
{
for(j=0;j<(i-1)-k;j++)
{
if(a[j]>a[j+1])
{
temp=a[j];
a[j]=a[j+1];
a[j+1]=temp;
}
}
}
//show the sorted data
printf("Thee sorted array is:\n");
for(int j=0;j<i;j++)
{
printf("%d",a[j]);
}
}
1
2
3
4
5
6
7
8
9
10
1
12
13
14
15
16
17
18
19
20
21
22
mvi b,03h
start: lxi h,var1
mvi c,03h
back: mov a,m
inx h
cmp m
jc ahead
mov d,m
mov m,a
dcx h
mov m,d
inx h
ahead: dcr c
jnz back
dcr b
jnz start
hlt
public class RemoveSpace{ public static void main(String args[]){ String str = "8085"; Sysytem.out.println(str.trim()); } } Get The Desired OutPut....
; Exact answer: LXI H, FFFFH push H POP PSW
The data bus of 8085 is 8 bit and so it will read or write 8 bits simultaneously.So it is Parallel Devise
VHDL is a hardware description language. It describes the functionality of a hardware as a program. If we know the architecture of 8085, the same can be implemented or coded using VHDL.
with neat diagram explain the system bus structure of 8085
how to write a program for matrix multiplication in microprocesspr
write it in 8085
Either in Assembly or in some high level language/the hex-code (for the mnemonics) that the microprocessor 8085 generally understands.
we want relay interface with 8085 and also attech the program
public class RemoveSpace{ public static void main(String args[]){ String str = "8085"; Sysytem.out.println(str.trim()); } } Get The Desired OutPut....
; Exact answer: LXI H, FFFFH push H POP PSW
Sp[[Q/Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 matrix|Answer]]ell chec[[Q/Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 matrix&action=edit&section=new|Answer it!]]k your answe[[Q/Discuss:Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 matrix|Disc]][[help/answering questions|guidelin]]Spell check your answeresussionr[[help/signing in|full benefits]] Save C[[Q/Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 matrix|Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 ]][[Q/Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 matrix&action=edit&section=new|Answering 'Write a 8085 microprocessor program to find A inverse and A transpose if A is a 3x3 matrix?']]matrix?ancel[[Q/How many animals are in West Texas|How many animals are in West Texas?]][[Q/How do you increase the number of four wheelers vehicles for servicing in a Service workshop|How do you increase the number of four wheelers vehicles for servicing in a]][[Q/How do you increase the number of four wheelers vehicles for servicing in a Service workshop|How do you increase the number of four wheelers vehicles for servicing in a Service workshop?]] Service workshop?[[Q/How do you increase the number of four wheelers vehicles for servicing in a Service workshop|How do you increase the number of four wheelers vehicles for servicing in a Service workshop?]]More Q&A
A program which is used to count the number of numbers in an array using a 8085 microprocessor is known as a assembly language program.
program to find prime number in 8085 microprocessor
jump,b
It can be implemented very easily .... Suppose the Binary word is X7X6X5.... X0 then the corresponding Gray code is G7G6G5....G0 where G7=X7 G6=X7 XOR X6 G5=X6 XOR X5 ..... G0=X1 XOR X0 Now implement the above algorithm
in 8085 microprocessor a subroutine is a separate program written aside from main program ,this program is basically the program which requires to be executed several times in the main program. the microprocessor can call subroutine any time using CALL instruction . after the subroutine is executed the subbroutine hands over the program to main program using RET instruction.