Session 5 - Python

  

Geany saves each time the program is Run.

1. Basics

  1. This is what a basic python script looks like.

  2. Python has many unique characteristics including algebra.

  3. Python uses all the familiar Maths operations.

  4. In other languages such as Canvas scripts are indented for neatness.
    Python indentation is much more powerful.

  5. Text files can be created and information stored.


  1. Arrays are useful when using loops.

  2. Python uses function calls like other programming languages.
    Values, called arguments, can be passed to functions.



  3. Simple ASCII Art.


  4. The roots of a parabola are calculated.
    Where the value of y is 0.



  5. Two functions are called to calculate and display factorials.



Library Files

Some library files come with Python and others have to be installed.

If library file is missing an error message is shown.


2. Graphs

  1. Use MathPlot Library.
    MathPlot



  2. Add Numpy Library.



  3. Draw a Parabola based on Coefficients.




3. Shapes

  1. Draw Red Square


  2. Draw a Polygon


    Activity

    Draw a 5 Pointed Star.


4. Charts
रेखांकन

  1. Copy Histogram Code into Geany
    हिस्टोग्राम कोड को गेनी में कॉपी करें



  2. Copy Pie Chart Code into Editor
    संपादक में पाई चार्ट कोड कॉपी करें



  3. Use different labeling.
    विभिन्न लेबलिंग का प्रयोग करें।



  4. Input data.
    इनपुट डेटा।




5. Movement
आंदोलन

  1. Copy into Geany and Run
    गेनी और रन में कॉपी करें



  2. Turning Circle
    मोड़ चक्र



  3. Make Crab Walk using Arrow Keys
    तीर कुंजी का उपयोग कर केकड़ा चलना बनाओ



Top Start

चोटी प्रारंभ