Skip to content

Arisa-Kaewsuan/Python_Tutorial

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Python   Python

  •   Python ใช้ทำอะไรได้บ้าง ?

     1. ใช้ทำโปรแกรมแบบมี GUI : ใช้ library เช่น Tkinter , PyGTK , PyQT , JPython , Kivy , wxPython , ... 2. ใช้ทำเกม : ใช้ library เช่น pygame 3. ใช้ในงานสาย Data Science : ใช้ library เช่น pandas , Numpy , seaborn , mathplotlib 4. ใช้ในงานสาย IoT (Internet of Thing) : Arduino , ทำ Robot , Raspberry pi 5. ใช้ทำ web : ใช้ library เช่น Django , Flask 
  • &nbps; เริ่มใช้ Python ยังไง ?

     1. install python : คือ โปรแกรมแปลภาษาไพธอนเป็นภาษาเครื่อง เราก็จะสามารถเขียนไพธอนด้วย editor/IDE แล้วรันดูผลลัพธ์ได้ 2. install editor : มีให้เลือกใช้เยอะมาก เช่น vscode (นิยมใช้สำหรับผู้เริ่มต้น), pycharm , Google colab (นิยมใช้สำหรับผู้เริ่มต้น สะดวกมากใช้บนเว็บได้เลย แค่มีบัญชี Google ), sublimetext (สำหรับคนใช้ mac) , Jupyter (นิยมใช้ในงาน data science) , Spyder (อาจารย์ชอบใช้สอนตามมหาลัยสาย data science ทำ ML) โดยภาษา Python จะสามารถ Run ได้ 2 แบบ 1. Interpreter : การรันแบบ interpret คือการ run ที่ละบรรทัด เหมาะใช้ในงาน Data science 2. Compliler : การรันแบบ compile คือการที่เราเขียนเป็นไฟล์แล้ว run ทั้งหมดทีเดียว 



  •   PYTHON  BASIC

    •   syntax  :  indent สำคัญมาก เพราะ ไม่ใช้ {} และ ; ในการแบ่งบล็อคโค้ดเหมือนภาษาอื่น
         หลังเงื่อนไข (condition) มี : (colon)เสมอ เช่น เงื่อนไข if-else , เงื่อนไข loop
         เป็น Dynamic Programming ไม่ต้องระบุ Data type เหมือนภาษา java

    •   input  :  x = input('Enter your name:')

    •   output  :  print("Hello World !")

    •   Math  :  x = min(5, 10, 25)    x = max(5, 10, 25)    x = pow(4, 3)    x = math.sqrt(64)    x = math.pi
                     y = math.floor(1.4)   x = math.ceil(1.4)

    •   condition  :  if b > a:    elif a == b:    else:    TERNARY OPERATOR : print("A") if a > b else print("B")

    •   loop  :  while    ARRAY-LOOP : for x in array:    break    continue

    •   ในภาษา python มีชนิดข้อมูล (Data type) อะไรบ้าง ?  :  String    Tuple    List    Set    Dictionary    Boolean    Integer   Double

    •   Array  :  python ไม่มี Array แต่สามารถใช้ List เป็น Array ได้    CREATE : cars = ["Ford", "Volvo", "BMW"]    ACCESS : x = cars[0]    ARRAY-LENGHT : x = len(cars)    EDIT : cars[0] = "Toyota"    INSERT : cars.append("Honda")
         DELETE : cars.remove("Volvo")

    •   Tuple  :  CREATE : mytuple = ("apple", "banana", "cherry")    CHECK TYPE : print(type(thistuple))
         ACCESS : print(thistuple[1]) OR print(thistuple[2:5])    EDIT : y[1] = "kiwi"    ADD : y.append("orange")
         DELETE : y.remove("apple")
         ARRAY-LOOP : for i in range(len(thistuple)):    ARRAY-LOOP : for i in range(len(thistuple)):   

    •   List  : 

    •   Dictionary  : 

    •   Set  : 

    •   String  : 

    •   lampda  : 

    •   File  : 


  •   PYTHON  OOP
    •   Function  : 
    •   Class  : 
    •   Inheritance  : 
    •   Polymorphism  : 

  •   PYTHON  DATABASE
    •   MySQL  : 
    •   MongoDB  : 

  •   PYTHON  GUI
    •   TKinter  : 
    •   PyQT  : 

  •   PYTHON  WEB
    •   Django คืออะไร ?  : 
    •   Flask คืออะไร ?  : 
    •   web scrapping คืออะไร ?  : 
    •   API คืออะไร ?  : 

  •   PYTHON  DATA  SCIENCE
    •   Data Sciencetist ต่างจาก AI Engineer ยังไง ?  : 
    •   Data Engineer  :  pandas , spark , ci-cd
    •   Data Analyst  :  mathplotlib , Numpy



3. )    Python  Exercise

  •   Beginner  Level  ( เป็นโจทย์เหมาะสำหรับฝึกใช้คำสั่งพื้นฐานให้คล่อง ให้คุ้นเคยกับ syntax )  : 

  •   Intermediate  Level  ( เป็นโจทย์ที่ทำให้เราได้ฝึกเอาพื้นฐานมาประยุกต์ใช้สร้าง Product จริงๆ )  : 

    • practicepython :  โจทย์ส่วนมากเป็นเกม เช่น tic tac toe มีอธิบายโค้ด เหมาะใช้ฝึกอ่านทำความเข้าใจวิธีเขียนโค้ดของคนอื่น เพื่อมาประยุกต์ใช้
    • hackerrank  :  เลือกระดับได้ คล้ายๆ leetcode เหมาะใช้ฝึก interview coding เตรียมตัวก่อนไปสัมภาษณ์งาน
    • edabit  :  เลือกระดับได้ คล้ายๆ leetcode เหมาะใช้ฝึก interview coding เตรียมตัวก่อนไปสัมภาษณ์งาน
  •   Advanced  Level  ( เป็นการทำ Project อาจจะ opensource )  : 

    • jetbrains  :  พาทำโปรเจคน่าสนใจ เช่น Password Hacker (Python) แต่ไม่ฟรี

About

: Python Programming

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages