Skip to main content

Posts

Showing posts with the label CBSE

Program to accept a number. Display the reverse of the number. Using Python

Program to accept a number. Display the reverse of the number. Input: 123 Output: 321 r=0 n = int(input("Enter a number:")) while n>0:     d=n%10     r=r*10+d     n=n//10 print("Reverse of the number is",r) ''' Dry Run r=0 n=123 123>0,True, d=123%10=3, r=0*10+3=3, n=123//10=12 12>0,True, d=12%10=2, r=3*10+2=32, n=12//10=1 1>0,True, d=1%10=1, r=32*10+1=321, n=1//10=0 0>0,False Reverse of the number is 321 '''

CBSE Class 9 AI Chapter 8 Computer System MCQs

**Components of Computer System: Multiple Choice Questions** **1. What are the three main types of components in a computer?** a) Hardware, Software, Peripheral b) Input, Processing, Output c) CPU, RAM, Hard Drive d) Monitor, Keyboard, Mouse **Answer: b) Input, Processing, Output** **2. According to the document, what is the role of input devices analogous to in a human?** a) The brain b) The hands and legs c) The five senses d) The memory **Answer: c) The five senses** **3. Which of the following is NOT a hardware component?** a) Microsoft Excel b) Monitor c) Motherboard d) Keyboard **Answer: a) Microsoft Excel** **4. The Central Processing Unit (CPU) is responsible for all EXCEPT:** a) Controlling the sequence of operations b) Storing data permanently c) Providing instructions to other parts d) Controlling the memory **Answer: b) Storing data permanently** **5. Which component of the CPU is responsible for performing arithmetic operations like addition and subtraction?** a) Control U...