Python Variables Explained for Beginners

🚀 Python Variables Explained (Beginner Friendly) Today I practiced Python variables and naming conventions 1. Basic Variable Declaration name = "Ankaj" age = 36 salary = 50000 print("Name:", name) print("Age:", age) print("Salary:", salary) 2. Variable Naming Rules user_name = "Ankaj" age1 = 25 _salary = 30000 print(user_name) print(age1) print(_salary) 3. Constants Convention (Uppercase) PI = 3.14 MAX_SPEED = 120 COMPANY_NAME = "ABC Pvt Ltd" print(PI) print(MAX_SPEED) print(COMPANY_NAME) Key Learnings: * Variables store data values * Naming rules matter in clean code * Constants are written in UPPERCASE by convention I’m building my Python skills step by step Follow Ankaj Python Hub for my daily learning journey #Python #Coding #LearnPython #100DaysOfCode #Programming

To view or add a comment, sign in

Explore content categories