Skip to content

Commit 5f1d2b4

Browse files
committed
code
1 parent 59c6c75 commit 5f1d2b4

File tree

8 files changed

+37
-8
lines changed

8 files changed

+37
-8
lines changed

02_Variables/variables.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@
1111

1212
#Let’s jump into computer screen.
1313

14+
15+
# YES, Python is a case-sensitive programming language. This means that it treats uppercase
16+
# and lowercase letters differently.
17+
# Hence, we cannot use two terms having same characters but different cases interchangeably in Python.
18+
1419
x= 5
1520
print('x')
1621

03_data_types/datatypes.py

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,22 @@
11

2-
#Numbers: Python has three types of numbers: integer, float, and complex. An integer is a whole number, a float is a number with a decimal point, and a complex number is a number with a real and imaginary part.
2+
#Numbers: Python has three types of numbers: integer, float, and complex. An integer is a whole number,
3+
# a float is a number with a decimal point, and a complex number is a number with a real and imaginary part.
34

4-
#Strings: A string is a sequence of characters, such as a word or a phrase. You can create a string by enclosing a series of characters in single or double quotes.
5+
#Strings: A string is a sequence of characters, such as a word or a sentence. You can create a string by
6+
# enclosing a series of characters in single or double quotes.
57

6-
#Lists: A list is an ordered collection of values that can be of any data type. You can create a list by enclosing a series of values in square brackets and separating them with commas.
8+
#Lists: A list is an ordered collection of values that can be of any data type. You can create a list by
9+
# enclosing a series of values in square brackets and separating them with commas.
710

8-
#Tuples: A tuple is similar to a list, but it is immutable, which means that you cannot modify the values in a tuple once it has been created. You can create a tuple by enclosing a series of values in parentheses and separating them with commas.
11+
#Tuples: A tuple is similar to a list, but it is immutable, which means that you cannot
12+
# modify the values in a tuple once it has been created. You can create a tuple by enclosing a
13+
# series of values in parentheses and separating them with commas.
914

10-
#Dictionaries: A dictionary is a collection of key-value pairs. You can create a dictionary by enclosing a series of key-value pairs in curly braces and separating them with commas.
15+
#Dictionaries: A dictionary is a collection of key-value pairs. You can create a dictionary by enclosing
16+
# a series of key-value pairs in curly braces and separating them with commas.
1117

12-
#Sets: A set is an unordered collection of unique values. You can create a set by enclosing a series of values in curly braces and separating them with commas.
18+
#Sets: A set is an unordered collection of unique values. You can create a set by enclosing a
19+
# series of values in curly braces and separating them with commas.
1320

1421
#Booleans: A Boolean value is either True or False.
1522

04_numbers/numbers.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
2+
3+
4+
#A number is an arithmetic value used for representing the quantity and used in making calculations
15
#Python has three built-in numeric data types: integers,
26
#floating-point numbers, and complex numbers
37

05_Strings/strings.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
#what is string
22

3+
# A string is a data type used in programming, that is used to represent text rather
4+
# than numbers. A string is a sequence of characters and can contain letters, numbers, symbols and even spaces.
5+
# It must be enclosed in quotation marks for it to be recognized as a string.
6+
37

48
x = "hello"
59
y = 'world'

06_Boolean/boolean.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11

22
what is Boolean
3-
#A Boolean value is either True or False. In Python, you can create a Boolean value by assigning True or False to a variable:
3+
#A Boolean value is either True or False. In Python, you can create a Boolean value by assigning
4+
# True or False to a variable:
45

56
#Example:
67

07_Operators/operators.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
# expression "4 + 5", the + symbol is the operator that performs the
44
# addition operation.
55

6+
1.#Arithmetic operators
7+
2. #Assignment operators
8+
3. #Comparison operators
9+
4. #Membership opertors
610

711
#Arithmetic operators
812
#Arithmetic operators are used to perform mathematical operations such as addition, subtraction, multiplication, and division.

09_Tuples/tuples.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
#A tuple is similar to a list, but it is immutable, which means that you cannot modify the values in a tuple once it has been created. In Python, you can create a tuple by enclosing a series of values in parentheses and separating them with commas:
1+
2+
#A tuple is similar to a list, but it is immutable, which means that you cannot modify the values
3+
# in a tuple once it has been created In Python, you can create a tuple by enclosing a series of
4+
# values in parentheses and separating them with commas:
25

36

47
x = (1, 2, 3)

10_Sets/sets.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
#A set is an unordered collection of unique values. In Python, you can create a set by enclosing a series
23
# of values in curly braces and separating them with commas:
34

0 commit comments

Comments
 (0)