3. what is python?
• general purpose
• open source
• object oriented and functional
• interpreted and interactive
• cross-platform
• portable
• sociable and outgoing
8. Java
import java.io.*;
public class Helloworld
{
public static void main(String[] args)
{
System.out.println("Hello World!");
}
}
comes in at a hefty 115 characters and 8 lines!
10. what makes python great?
➡comes batteries-included!
★
has comprehensive support for
routine acts in the form of modules
★
pythonic principle-don’t reinvent the
wheel
11. what makes python great?
➡incredible support
★
lots and lots of documentation
★
better yet! you have the interpreter,
the magic word being help(name)
★
in python, you have an ever-present
help!
12. what makes python great?
➡fantastic datatypes and dynamically typed
★
list
★
tuple
★
set
★
dictionary
★
string, int, float
13. datatype example
•
•
roll={10583: "Pratheek"}
•
•
•
•
name= "Pratheek Adidela"
sportplayed={badminton, tennis, badminton,
cricket, tennis, cricket}
phone=8091340241
Student=(name, roll, phone, sportplayed)
AllStudents is a list of tuples, each of which
consists of a string, dictionary, integer and set
14. let’s dig into the delicious
realm of string parsing
NLTK