What are variables and datatypes?
Variables are used to store and access the data. The datatype indicates the range of the the data and the memory allocated for that data. In java, we must specify the data type of the variable before using it (i.e) Statically typed. …
Why do we need programming languages ?
Programming languages basically have syntax and they instruct the CPU to do a particular job. The CPU can understand only 0’s and 1’s. If we try to write something using 0’s and 1’s, it would be really difficult for any human beings to…
Mutators and accessors :
Let me explain this with an example.
response= “ Hi ! Our HR will get back to you”
Here, “response” is an identifier.
“lower()” method is called mutator/update method. This will change the state of an object. …
Immutable ordered set of characters ( refer my post — day3) enclosed by single or double quotes.
Eg : print(‘Hello Harini’) / print(“Hello Harini”)
Welcome_message= “ Hello, You look so beautiful.”
Output : Hello, You look so beautiful.
What if you want to print “ ” / ‘ ’in…
prints the result of expression to the console.
Eg : print(5+3) prints 8 to the console.
Returns the data type of the variable/output .
Eg : print(type(9)) prints <class ‘int’> to the screen.
Note : We can convert float to int or int to float or…
Operators are used to perform operations on variables and values.
Python divides the operators in the following groups:
ARITHMETIC OPERATORS :
Let’s see with an example:
List is an example of mutable classes.
lst=(‘A’, ‘B’, ‘C’)
print(lst) — — — — (‘A’, ‘B’, ‘C’)
lst.append(‘D’) #append() adds an element to the end of a list
print(lst) — — — — (‘A’, ‘B’, ‘C’, ‘D’)
The append() adds the element ‘D’ to…
History of Python :
Python programming language was originally developed by GUIDO VAN ROSSUM in early 1990’s.
Python Interpreter :
Python is an interpreted language. Python Interpreter is a software which receives the command, evaluates the command and report the result of the command.
Python highly relies on…
In this blog, we are going to learn together by helping each other. PYTHON is the base topic for this blog. Throughout this blog, I am planning to cover all the topics needed to ace the coding interview starting from the basic to the advanced topics. So yeah ! …