Python

Write a Program in Python to find sum of digits of a given number.

Output: Enter Number to find sum of digits:123Sum of digits= 6 Explanation: What does this program do?It finds the sum of digits of a number entered by the user. Example:If the number is 123, the sum is 1 + 2 + 3 = 6 Line-by-Line Explanation1. Input from useri = int(input(“Enter Number to find sum

Python

Python MCQs Strings

Q1. Which data type is used to store text in Python? A) char B) string C) str D) text Show Answer ✅ Correct Answer: (C) str 📘 Explanation: Python uses the str data type to store text. Q2. Which of the following is the correct way to create a string? A) ‘Hello’ B) Hello C)

Python

Python MCQs Function

Q1. What is a function in Python? A) A variable B) A block of reusable code C) A data type D) A loop Show Answer ✅ Correct Answer: (B) A block of reusable code 📘 Explanation: A function is a reusable block of code that performs a specific task. Q2. Which keyword is used to

Python

Python MCQs Control Statements (if, loops)

Q1. Which keyword is used for conditional execution in Python? A) switch B) if C) when D) select Show Answer ✅ Correct Answer: (B) if 📘 Explanation: if is used to test a condition and execute code accordingly. Q2. Which statement is used when an if condition is false? A) else B) elseif C) when

Python

Python MCQs Operators

Q1. Which operator is used for addition in Python? A) * B) + C) – D) / Show Answer ✅ Correct Answer: (B) + 📘 Explanation: The + operator is used to add two values. Q2. Which operator is used to find the remainder of a division? A) / B) // C) % D) **

Python

Python MCQs Data Types

Q1. Which of the following is a built-in data type in Python? A) real B) float C) double D) character Show Answer ✅ Correct Answer: (B) float 📘 Explanation: float is a built-in Python data type used to store decimal values. Q2. Which data type is used to store whole numbers in Python? A) float

Python

Python MCQs Algorithm, Flowchart, Pseudocode

Q1. What is an algorithm? A) A programming language B) A flowchart C) A step-by-step procedure to solve a problem D) A software Show Answer ✅ Correct Answer: (C) A step-by-step procedure to solve a problem 📘 Explanation: An algorithm is a finite, ordered set of steps used to solve a specific problem. Q2. Which

Python

Python MCQs Variables

Q1. What is a variable in Python? A) A keyword B) A data type C) A memory location used to store a value D) A function Show Answer ✅ Correct Answer: (C) A memory location used to store a value 📘 Explanation: A variable stores data values in memory and can change during program execution.

Python

Python MCQ Basics

Q1. Who developed the Python programming language? A) James Gosling B) Dennis Ritchie C) Guido van Rossum D) Bjarne Stroustrup Show Answer ✅ Correct Answer: (C) Guido van Rossum 📘 Explanation: Python was created by Guido van Rossum in the late 1980s while working at CWI, Netherlands. Q2. In which year was Python first released?

Domain

How to Check Domain Age of a Website – Step By Step Guide

How to Check Domain Age of a Website – Step By Step Guide If you want to start a website for your business or personal blog and are thinking of buying a domain for it, then it is very important for you to know the age of the domain here. In this article we will

Scroll to Top