15-122: Principles of Imperative Computation,
Summer 2011
Assignment 8: The C0VM
William Lovas ([email protected])
Tom Cortina ([email protected])
Frank Pfenning ([email protected])
Out: Thursday, June 16, 2011
Due: Thursday,
15-122 : Principles of Imperative Computation, Spring 2016
Written Homework 2
Due: Monday 25th January, 2016
Name:
Andrew ID:
Section:
This written homework covers more reasoning using loop invariants
15-122 : Principles of Imperative Computation, Fall 2014
Written Homework 2
Due: Monday, September 8, 2014
Name:
Andrew ID:
Section:
This written homework covers more reasoning using loop invariants a
15-122 Homework 4
Page 1 of 10
15-122 : Principles of Imperative Computation, Spring 2013
Homework 4 Theory
Due: Thursday, March 7, 2013, at the beginning of lecture
Name:
Andrew ID:
Recitation:
The w
15-122 : Principles of Imperative Computation, Spring 2016
Written Homework 3
Due: Monday 1st February, 2016
Name:
Andrew ID:
Section:
This written homework covers specifying and implementing search i
15-122 : Principles of Imperative Computation, Fall 2014
Written Homework 4
Due: Monday, September 22, 2014
Name:
Andrew ID:
Section:
This written homework covers big O notation and some reasoning abo
15-122 Homework 1
Page 1 of 6
15-122 : Principles of Imperative Computation, Spring 2013
Homework 1 Theory
Due: Tuesday, February 5, 2013, at the beginning of lecture
Name:
Andrew ID:
Recitation:
The
15-122 Assignment 6
Page 1 of 5
15-122 : Principles of Imperative Computation
Fall 2012
Assignment 6 Selected Solutions
(Theory Part)
The following solutions are provided to you to help you study this
15-122 Assignment 4
Page 1 of 8
15-122 : Principles of Imperative Computation
Summer 1 2012
Assignment 4
(Theory Part)
Due: Monday, June 11, 2012 in class
Name:
Andrew ID:
Recitation:
The written port
15-122 : Principles of Imperative Computation, Fall 2014
Written Homework 3
Due: Monday, September 15, 2014
Name:
Andrew ID:
Section:
This written homework covers specifying and implementing search in
15-122 Homework 1
Page 1 of 12
15-122: Principles of Imperative Computation, Spring 2013
Homework 1 Programming: Imagelab
Due: Monday, February 4, 2013 by 23:59
For the programming portion of this wee
15-122 : Principles of Imperative Computation, Fall 2014
Written Homework 5
Due: Monday, September 29, 2014
Name:
Andrew ID:
Section:
This written homework covers asymptotic complexity for a new algor
15122: Principles of Imperative Computation
M IDTERM E XAM 1
S AMPLE S OLUTIONS
October 2, 2014
This exam is closed book with one sheet of notes permitted.
You have 80 minutes to complete the exam.
15-122: Principles of Imperative Computation
Recitation 3: Function Family Reunion
Spring 2017
3 February
Big-O denition
The denition of big-O has a lot of mathematical symbols in it, and so can be ve
15-122: Principles of Imperative Computation, Spring 2017
Written Homework 4
th
Due: Monday 13
February, 2017 by 9pm
Name:
Andrew ID:
Section:
This written homework covers big-O notation and some reas
Spring 2017
15-122: Principles of Imperative Computation
Recitation 1: C0 Basics
23 January
Administrivia and general advice
Welcome to 15-122 recitation! Take a moment to ll in the particulars for th
15-122: Principles of Imperative Computation, Spring 2017
Written Homework 1
Due:
rd
Monday 23
January, 2017 by 9pm
Name:
Andrew ID:
Section:
This written homework is the rst of two homeworks that wil
Spring 2017
15-122: Principles of Imperative Computation
Recitation 4: A Strange Sort of Proof
In class, we covered one quadratic sort,
selection sort.
10 February
Today, we'll look at the full correc
Spring 2017
15-122: Principles of Imperative Computation
Recitation 2: A Bit About Bytes
27 January
Converting between binary and decimal
To easily convert a number represented in binary notation, suc
Spring 2017
15-122: Principles of Imperative Computation
Recitation 5: A queue_t Interface
17 February
A Wild struct Appears
Suppose we have the following denitions:
struct X cfw_
int a;
struct Y* b;
15-122 Programming Homework 4
Page 1 of 9
15-122: Principles of Imperative Computation, Spring 2017
Programming Homework 4: DosLingos
Due: Thursday 16
th
February, 2017 by 9pm
This week we will do som
36-202 Fall 2017
Homework 1
NAME: _
Andrew ID: _
Circle your lab section:
Section A
(10:30 Baker)
Section B
(10:30 Baker)
Section C
(10:30 Baker)
Section E
(1:30 Wean)
Section D
(2:30 Wean)
Print out
Homework 2
36-202 Fall 2017
Due: Friday, September 20, at the beginning of lecture.
Instructions:
1. Write up your solutions on separate paper, with your name on all pages.
2. The work and words that
Lecture 2 Notes
Number notations have a base b. To write down numbers in base b we need b
distinct digits.
In computer systems, two bases are of particular importance: binary (base 2)
and hexadecimal
Homework 1
36-202 Fall 2017
Due: Wednesday, September 13, at the beginning of lecture.
Instructions:
1. Write up your solutions on separate paper, with your name on all pages.
2. The work and words th
http:/cs.cmu.edu/~15122/hw/images-handout.tgz
README.txt
http:/cs.cmu.edu/~15122/misc/styleguide.pdf
cc0
-w
pixel.c0
@requires @ensures
@loop_invariant
imageutil.c0
-w
55
a
f
k
p
u
b c d e
g h i j
l m
15-122: Principles of Imperative Computation, Spring 2017
Written Homework 11
Due: Thursday 13
th
April, 2017 by 9pm
Name:
Andrew ID:
Section:
This written homework provides practice with some introdu
Midterm 1 Solutions
15-122 Principles of Imperative Computation
Saquib Razak, Rob Simmons, and Hyrum Wright
February 17, 2015
Name:
Andrew ID:
Harry Bovik
bovik
Recitation Section (specify letter or T
Lecture 1
Contracts
15-122: Principles of Imperative Computation (Fall 2017)
Frank Pfenning
1
Introduction
In these notes we review contracts, which we use to collectively denote
function contracts, l
Written 2 Notes
09/09/2017
Five kinds of safety violations thus far:
Putting in parameters that dont satisfy the functions /@requires annotation
Division or modulo by zero
Bitshifting an integer le