Hey, Here is the Day 3 updates of my Python learning journey! Today, I explored two essential concepts that make Python a flexible and powerful programming language: Dynamic Typing and Mutable vs Immutable Types . Let's dive deep into these topics! Understanding Dynamic Typing in Python Python is a dynamically typed language, meaning that variable types are determined at runtime . Unlike statically typed languages such as Java or C++, where you need to declare the type of a variable explicitly, Python allows you to assign any value to a variable without specifying its type. Example of Dynamic Typing: x = 10 # x is an integer print(type(x)) # Output: <class 'int'> x = "Hello" # x is now a string print(type(x)) # Output: <class 'str'> x = [1, 2, 3] # x is now a list print(type(x)) # Output: <class 'list'> Key Takeaways: No need to declare variable types in Python. The same variable can hold different types of data ...
Hey! I’m back with my Day 2 update on my Python learning journey. Today was all about getting hands-on with variables, data types, and basic operations. I spent decent 3 hours and to write blog additional 1 hour to summarize my learning. bit hectic however its being weekend i thought of spend more time today on basics to get along with programming so that i can invest less time during weekdays. It feels so satisfying to be writing more complex code already, even though I’m still just scratching the surface! Here’s a quick rundown of what I’ve learned: Firstly, Downloaded and configured the VSCode on my windows Laptop. and executed Hello World command. then moved ahead with learning basic Syntax and Structure ( print(), comments, indentation) Variables & Data Types I learned how to store information in variables and use different data types like strings, integers, floats, and booleans. For example, I learned how to assign values like name = "Sri Ram" and age = ...