Course and Reading Material

One Dimensional Lists and Strings in Python

Formating floating point: b=float("{0:.2f}".format(a))

Future Plans

Jan 22 Lecture Practice

The Community Center in City A offers a wide range of activities: various group exercise classes, gym, swimming pool, personal training, etc. For each activity, the Center publishes the number of calories could burnt during 1 hour for each activity. Write a program that reads the number of activities person participated during one week. The program creates a list of activity names - list of strings - user input. The program also randomly generates a list of integers - number of hours spent on each activity per week. The program also randomly generates a list of integers - the number of calories that could be burnt for 1 hour for each activity. The program creates a new list - total_calories. Each entry in the list is the total number of calories burnt per week per activity. The program also finds the activity with minimal number of calories burnt per week.
See example below:

activity_names=["Yoga", "Tai-Chi", "Swimming", "Running", "Walking"]

calories_per_hour=[154, 240, 400, 600, 340]

hours_per_week=[6, 3, 2, 2, 3]

total_calories=[924, 720, 800, 1200, 1020]

the activity with minimal calories burnt per week - Tai-Chi, with 720 calories burnt per week.


MINI QUIZ 1 - DUE DAY MONDAY 10 AM


Lecture Practice Wed Feb 3

Test 1 Feb 5

Two Dimensional Lists

List initialization:

Option 1:
a = [[ 0 for i in range(COL)] for j in range(ROW)]
The above line will create a list of ROW rows and COL columns and assign value 0 to each element

Option 2



Mini Quiz Friday Feb 12



Test 2
  • Test 2
  • Lecture and Lab Practice Feb 24- Test Preparation


    Program 1
    Program 2
    Program 3
    Program 4

    Tuples and Dictionaries in Python

  • Tuples and Dictionaries in Python
  • Some Dictionaries Methods
  • Sorting Dictionaries

    Test 3

    Test 3




    Part II of the course: Programming with C

    Course material for Programming with C




    Exam 1 Preparation - C Programming Language

    Exam Date: Friday April 1, 2016


    Exam 1 Programming in C




    mini quiz April 15

    mini quiqz april 15


    Challenge

    problems

    Exam 2 C Programming

    Exam 2

    MINI QUIZ MAY 6

    Mini Quiz May 6