JCL

FEUP/DEI & INESC TEC

User Tools

Site Tools


teach:fpro:lectures:02

LE02: 15/10/2020

Master in Informatics and Computing Engineering
Programming Fundamentals
Instance: 2020/2021


Lecture #2 :: 15/10/2020

Goals

By the end of this class, the student should be able to:

  • Describe and distinguish the concepts of variable, location, value, type
  • Identify the Python reserved words
  • Describe the concepts of statement and expression
  • Identify some of the Python operands and their precedence
  • Use operators with suitable operands
  • Describe the Python type conversion operations and use them
  • Describe how to get input, at runtime, from a user of the program

Content

  • 2. Variables, expressions and statements
    • 2.1 Values and data types
    • 2.2 Variables
    • 2.3 Variable names and keywords
    • 2.4 Statements
    • 2.5 Evaluating expressions
    • 2.6 Operators and operands
    • 2.7 Type conversion functions
    • 2.8 Order of operations
    • 2.9 Operations on strings
    • 2.10 Input
    • 2.11 Composition
    • 2.12 The modulus operator
    • 2.14 Exercises

Bibliography

  • Peter Wentworth, Jeffrey Elkner, Allen B. Downey, and Chris Meyers, How to Think Like a Computer Scientist — Learning with Python 3, Release 3rd Edition, 2020 [PDF] (Chapter 2)

Materials

  • J. Correia Lopes, Study materials, GitHub (Notebook 02 - Variables, expressions and statements)
  • Brad Miller and David Ranum, Learning with Python: Interactive Edition. Based on material by Jeffrey Elkner, Allen B. Downey, and Chris Meyers [HTML] (Chapter 2)
  • ZOOM lecture's room (requires password): https://videoconf-colibri.zoom.us/j/83800564127
  • Moodle, Activity LE02
  • Moodle, Official App for Android at the Play Store

Summary

  • Simple Python Data. Variables, expressions and statements. Operators and precedence. Values, data types, and type casts. Operations on strings. Input.

FPRO, 2020/21

« Previous | Index | Next »

teach/fpro/lectures/02.txt · Last modified: 15/10/2020 09:31 by Correia Lopes