First Python Program
Python is beginner-friendly and easy to write. Let's start with a simple program that prints a message on the screen.
-
🧑💻Code Example:
print("Welcome to ShikshaSanchar!")
Output:
Welcome to ShikshaSanchar!
📝 Explanation:
print() is a built-in Python function used to display messages or output on the screen.
It is one of the most commonly used functions for:- Debugging your program
- Showing messages to the user
- Printing results of calculations or logic
This function is very useful when learning Python, as it helps you understand what's happening in your code.
-
💻 Code Example:
print("ShikshaSanchar is a learning platform.") print("ShikshaSanchar empowers you to learn, practice, and grow")
Output:
ShikshaSanchar is a learning platform.
ShikshaSanchar empowers you to learn, practice, and grow
📝 Explanation:
- The
print()
function is used to display text on the screen. - We can use multiple
print()
statements to show more than one line of output. - Strings (text) are written inside double quotes
""
.
- The