← Back to 6. Programming of 8085

📝 Programs to find largest or smallest number in 8085 Microprocessor

📖 From An Introduction To Microprocessor 8085 • 6. Programming of 8085 • 10 questions available

Practice MCQs for Programs to find largest or smallest number in 8085 Microprocessor. Test your knowledge with carefully crafted questions across easy, medium, and hard difficulty levels.

🔄 Last updated: 2026-07-30

2
Easy Questions
5
Medium Questions
3
Hard Questions

📝 Sample Questions

Q1. Which 8085 instruction produces the 1's complement of the accumulator?

🔹 A. CMA
🔹 B. RLC
🔹 C. DCR
🔹 D. INR

💡 Difficulty: easy | ✅ Correct: A

Q2. Three unsigned bytes are stored at memory locations 2500H, 2501H, and 2502H. Which code fragment correctly finds the largest value and stores it at 2503H?

🔹 A. LDA 2500H → MOV B,A → LDA 2501H → CMP B → JC SKIP → MOV B,A → SKIP: LDA 2502H → CMP B → JC END → MOV B,A → END: MOV A,B → STA 2503H
🔹 B. LDA 2500H → MOV C,A → LDA 2501H → CMP C → JNC NEXT → MOV C,A → NEXT: LDA 2502H → CMP C → JNC DONE → MOV C,A → DONE: MOV A,C → STA 2503H
🔹 C. LDA 2500H → MOV A,B → LDA 2501H → CMP B → JC KEEP → MOV B,A → KEEP: LDA 2502H → CMP B → JC DONE → MOV B,A → DONE: MOV A,B → STA 2503H
🔹 D. LDA 2500H → MOV D,A → LDA 2501H → CMP D → JZ SKIP → MOV D,A → SKIP: LDA 2502H → CMP D → JZ END → MOV D,A → END: MOV A,D → STA 2503H

💡 Difficulty: medium | ✅ Correct: B

Q3. The following fragment aims to find the largest of three numbers, but it contains a bug. Identify the bug and the correct fix.\nLDA 3000H\nCMP B\nJC SKIP\nMOV B,A\nSKIP: LDA 3001H\nCMP B\nJC DONE\nMOV B,A\nDONE: STA 3002H

🔹 A. The bug is using CMP B instead of CMP M; fix by replacing CMP B with CMP M
🔹 B. The bug is loading the first number into B instead of A; fix by using MOV A,B after LDA
🔹 C. The bug is comparing the accumulator with B before B holds a value; fix by initializing B with the first number using MOV B,A after the first LDA
🔹 D. The bug is storing the result in the wrong address; fix by changing STA 3002H to STA 3003H

💡 Difficulty: hard | ✅ Correct: C

⬆️ View all questions in the quiz below

🔗 Related Topics

📝 Simple Programs in 8085 Microprocessor📝 BCD to Binary Conversion in 8085 Microprocessor📝 Binary to BCD (Unpacked) Conversion in 8085 Microprocessor📝 Binary to ASCII Conversion in 8085 Microprocessor📝 ASCII to Binary Conversion in 8085 Microprocessor
🚀 Start Quiz 📝 Practice Mode