Python

Cards (36)

  • Introduction to the core concepts of computing: Problems and problem-solving
  • Types of problems
    • Routine problems
    • Non-routine problems
  • Method of solving computing problems
    • Algorithms
    • Heuristics
  • Solvable problems
    Problems that can be solved
  • Unsolvable problems

    Problems that cannot be solved
  • Solution techniques of solving problems
    • Abstraction
    • Analogy
    • Brainstorming
    • Trial and error
    • Hypothesis testing
    • Reduction
    • Literal thinking
    • Means end analysis
    • Method of focal object
    • Morphological analysis
    • Research
    • Root cause analysis
    • Proof
    • Divide and conquer
  • General Problem-solving process
    Identification of problem<|>Solution formulation and design<|>Implementation<|>Evaluation and refinement
  • Solution formulation and design: flowchart, pseudocode, decision table, decision tree
  • Implementation, evaluation and refinement
  • Programming in Python
  • Computer program
    A sequence of instructions written using a Computer Programming Language to perform a specified task by the computer
  • Computer programming
    The act of writing computer programs
  • Programming languages
    • Python
    • Java
    • C++
  • Categories of programming languages
    • Machine languages (first generation languages)
    • Assembly languages (second generation languages)
    • Third generation languages
    • Fourth generation languages
    • Natural languages
  • Low level languages
    Machine and assembly languages
  • High level languages
    Third generation, fourth generation and natural languages
  • Fundamentals of Programming
    • Programming Environment
    • Basic Syntax
    • Data Types
    • Variables
    • Keywords
    • Basic Operators
    • File I/O
    • Decision Making
    • Loops
    • Numbers
    • Characters
    • Arrays
    • Strings
    • Functions
  • Programming Environment Setup
    The first step to be followed before setting on to write a program, a base/platform on top of which we can do our programming
  • Our environment for this course is on Colab platform online
  • Python syntax can be executed by writing directly in the Command Line
  • Syntax

    The spelling and grammar of a programming language, which control which words the computer understands, which combinations of words are meaningful, and what punctuation is necessary
  • Types of programming languages based on syntax
    • Text-based programming languages
    • Visual programming languages
  • Syntax differences between programming languages
  • Syntax errors and error checking in IDE
  • Basic Syntax elements

    • Number and String (characters)
    • Keywords
    • Python Variables
    • Comments
    • Functions
    • Python Indentation
  • Python Indentation
    Indentation refers to the spaces at the beginning of a code line, which in Python is very important to indicate a block of code
  • Numeric types in Python
    • Integer (int)
    • Decimal (Float)
    • Complex
  • String literals in Python
    Surrounded by either single quotation marks, or double quotation marks
  • Strings are Arrays in Python
  • Escape Character
    Used to insert characters that are illegal in a string
  • Variable

    A place in computer memory where you can store values temporarily and use them later, represented as a symbol or name associated with a value and whose associated value may be changed
  • What variables can represent
    • Numeric values
    • Characters
    • Character strings
    • Memory addresses
  • Using variables allows the same program to process different sets of data
  • Rules for Python variables
    • Must start with a letter or underscore
    • Cannot start with a number
    • Can only contain alphanumeric characters and underscores
    • Case-sensitive
  • Exercises: Creating Variables, Assigning Value to Multiple Variables, Variable Output, String Concatenation, Global Variables
  • Learn Python Online at https://www.w3schools.com/python/default.asp