Translate

Python

PYTHON


5 Thing you need to know about the Python

Author - Rabiyul.H

1.Syntax
2.Versaility
3.Powerful tool
4.Community
5.Resources

Free e book -python mastery course

1.Syntax:

Sytax is basically that how you coded structure in terms of symbols and commands the way you use.

Syntax is Word is on the expression and punctuation there you used to tell computer different commands and lot of the time you used those include brackets coluumn, semi-column, etc..and other different symbol used in a python.
Punctuation -Basically computer needs to understand this is one sentence and this is another sentence is just like the way you using punctuation.
Python syntax is very clean it aoesnt have many braket (or) semicolumn as well as simple java script just the command .the words himself code is very very easy to read by humans for Example
Print(“Python is very easy to learn”)
Print (“Python is awesome”)
Because python is so clean. When it come to syntax its super readable. Its  very beginner friendly. So if you learn from scratch is easy one and if you finished a python programmming language defenitely you have a good carreer growth. Then why are you waiting for learn python today and defenitely you will be earn tomorrow.

2.versatility:

What is versatility? What you learn from it ?
Python is awesome. Not just like other programming languages because of how easy to read.versatility you can use for web development and also use for data science. Which is incredible to think about it. You learn python but you can do multiple things. If its possible in some other languages defenitely nope. If had possibility for upcoming generations. But now a days python facts and research shows in 2016 to 2019 still its a top most programming languages for data science and its scientfic language. If you learn python you can do different things like a machine learning and AI - Artificial Intelligence. 
so if you not decided what you like to do. You know you want to start and defenitely you have a great scope In web development and data science ,AI-Artificial Intelligence, Machine learning. These are all the platform you will be eligible to walkin for a job is just a amazing stuff right.

3.Powerful tool:

Increase of previous reason not attract you and your not already studying pyhton. Let me give you a another one example for a best multiple things. Used to do that you will be surprised how many top company’s using python. Actually they need more and more developers almost everyday to help and support your system to name the company’s below
1.Google
2.Facebook
3.Instagram
4.NASA
5.IBM
6.Pintrest
7.Spotify
8.Amazon
9.Quora
10.Reddit
11.Netflix Etc…
Lot of company using pyhton. Reason is so simple, versatility, easy to maintain and founders of google says “python where we can c++ where we want”.


4.Community:

Another huge benefits of python factors such a huge community of development who know is and why would I need a community. well I am a programmer .I am developing web application well my friend is community. Its very hard when you are building something explain the function something like that and you are stuck you either you don’t no
How to do that (or ) you have a bug you cant find and that is when the community step in and help you you can either you ask developer community too either too either give your device find the bug that cant locate (or) you can search come up community and some body already facing and find the solution that mean they already had a solution.
Ask a question and get your answer from your community aspects and trust me knowimg the programming language is not enough.
Google In different questions and problem might have becomes very influence skill because why invented real somebody already invented.somebody already had a problem and already solve the problem. That only reason you need community because lot of people learn python as a 1st and 2nd or 3rd programming language. If you have a problem then defenitely community answer the draw back and you   believe or not 2017 to still pythonf is a 2nd  top most popular programming language.

5.Resources:

The more company people use python more resources. they are allow "from framework to library". Use can more effencial manner .think as a  developer .I hope you can learn it will be very useful for you son many different area..
Machine learning 
               
Python projects 



Learn complete python course from scratch in you tube channel I given below




  • The following link is official website of mosh .giving a better learning for each and invidual from scratch .


Reference of code with mosh.com

Python basics

PYTHON
Basic
a = 1 (integer)
b = 1.1 (float)
c = 1 + 2j (complex)
d = “a” (string)
e = True (boolean)
Variables Escape sequences
\”
\’
\\
\n
x = “Python”
len(x)
x[0]
x[-1]
x[0:3]
Strings
name = f”{first} {last}”
Formatted strings
x.upper()
x.lower()
x.title()
x.strip()
x.find(“p”)
x.replace(“a”, “b”) “a” in x
String methods
round(x)
abs(x)
Numer functions
int(x)
float(x)
bool(x)
string(x)
Type conversion
Falsy values
0“”None
if x == 1:
print(“a”)
elif x == 2:
print(“b”)
else:
print(“c”)
Conditional statements Chaining comparison operators
if 18 <= age < 65:
x = “a” if n > 1 else “b”
Ternary operator
x and y (both should be true)
x or y (at least one true)
not x (inverses a boolean)
Boolean operators
For loops
for n in range(1, 10): …While loops
while n > 10: …
== (equal)
!= (not equal)
Equality operators
codewithmosh.com
Functions
def increment(number, by=1):
return number + by
increment(2, by=1)
Keyword arguments
Defining functions
Variable number of arguments
def multiply(*numbers):
for number in numbers:
print number
multiply(1, 2, 3, 4)
Variable number of keyword arguments
def save_user(**user): …
save_user(id=1, name=“Mosh”)
codewithmosh.com
Shortcuts
Start Debugging F5
Step Over F10
Step Into F11
Step Out Shift+F11
Stop Debugging Shift+F5
DEBUGGING CODING (Windows) CODING (Mac)
End of line fn+Right
Beginning of line fn+Left
End of file fn+Up
Beginning of file fn+Down
Move line Alt+Up/Down
Duplicate line Shift+Alt+Down
Comment Cmd+/
End of line End
Beginning of line Home
End of file Ctrl+End
Beginning of file Ctrl+Home
Move line Alt+Up/Down
Duplicate line Shift+Alt+Down
Comment Ctrl+/
codewithmosh.com
Lists codewithmosh.com
Creating lists
letters = ["a", "b", "c"]
matrix = [[0, 1], [1, 2]]
zeros = [0] * 5
combined = zeros + letters
numbers = list(range(20))
Accessing items
letters = ["a", "b", "c", "d"]
letters[0] # "a"
letters[-1] # "d" Slicing lists
letters[0:3] # "a", "b", "c"
letters[:3] # "a", "b", "c"
letters[0:] # "a", "b", "c", "d"
letters[:] # "a", "b", "c", "d"
letters[::2] # "a", "c"
letters[::-1] # "d", "c", "b", "a" Unpacking
first, second, *other = letters
Looping over lists
for letter in letters:
... for index, letter in enumerate(letters):
... Adding items
letters.append("e")
letters.insert(0, "-")
Removing items
letters.pop()
letters.pop(0)
letters.remove("b")
del letters[0:3]
Lists codewithmosh.com
Finding items
if "f" in letters:
letters.index("f")
Sorting lists
letters.sort()
letters.sort(reverse=True)
Custom sorting
items = [
("Product1", 10), ("Product2", 9), ("Product3", 11)
]
items.sort(key=lambda item: item[1])
Zip function
list1 = [1, 2, 3]
list2 = [10, 20, 30]
combined = list(zip(list1, list2))
# [(1, 10), (2, 20)]
Unpacking operator
list1 = [1, 2, 3]
list2 = [10, 20, 30]
combined = [*list1, “a”, *list2]
Tuples
point = 1, 2, 3
point = (1, 2, 3)
point = (1,)
point = ()
point(0:2)
x, y, z = point
if 10 in point: …
Swapping variables
x = 10
y = 11
x, y = y, x
Arrays
from array import array
numbers = array(“i”, [1, 2, 3])
Sets
first = {1, 2, 3, 4}
second = {1, 5}
first | second # {1, 2, 3, 4, 5}
first & second # {1}
first - second # {2, 3, 4}
first ^ second # {2, 3, 4, 5}
Dictionaries
point = {"x": 1, "y": 2}
point = dict(x=1, y=2)
point["z"] = 3
if "a" in point:
... point.get("a", 0) # 0
del point["x"]
for key, value in point.items():
... Comprehensions codewithmosh.com
List comprehensions
values = [x * 2 for x in range(5)]
values = [x * 2 for x in range(5) if x % 2 == 0]
Set comprehensions
values = {x * 2 for x in range(5)}
Dictionary comprehensions
values = {x: x * 2 for x in range(5)}
Generator expressions
values = {x: x * 2 for x in range(500000)}
Exceptions codewithmosh.com
Handling Exceptions
try: …
except (ValueError, ZeroDivisionError): …
else:
# no exceptions raised
finally:
# cleanup code
Raising exceptions
if x < 1:
raise ValueError(“…”)
The with statement
with open(“file.txt”) as file: …
Classes codewithmosh.com
Creating classes
class Point:
def __init__(self, x, y):
self.x = x
self.y = y
def draw(self): …
Instance vs class attributes
class Point:
default_color = “red”
def __init__(self, x, y):
self.x = x
Instance vs class methods
class Point:
def draw(self): …@classmethod
def zero(cls):
return cls(0, 0)
Magic methods
__str__() __eq__() __cmp__()
Classes codewithmosh.com
Private members
class Point:
def __init__(self, x):
self.__x = x
Properties
class Point:
def __init__(self, x):
self.__x = x
@property
def x(self):
return self.__x
@property.setter:
def x.setter(self, value):
self.__x = value
Inheritance
class FileStream(Stream):
def open(self):
super().open() …Multiple inheritance
class FlyingFish(Flyer, Swimmer): …Abstract base classes
from abc import ABC, abstractmethod
class Stream(ABC):
@abstractmethod
def read(self):
pass
Classes codewithmosh.com
Named tuples
from collections import namedtuple
Point = namedtuple(“Point”, [“x”, “y”])
point = Point(x=1, y=2)

1. String - Series of character
2. Integer -WIthout using decimal point
*Career
Python Developer. Becoming a Pythondeveloper is the most direct job out there for someone who knows thePython programming language. ...
Product Manager. ...
Data Analyst. ...
Educator. ...
Financial Advisors. ...
Data Journalist.

You can view the book and you can download the books also 

to embed in website:

Comments

Popular Posts

bot

Popular post