Course topics
- ๐งฉ
- Modularity
- โ
- Correctness
- ๐ ๏ธ
- Real-world engineering
The syllabus below is provisional and provided for informational purposes only. It will be updated throughout the semester. See Moodle for binding deadlines.
1
)
released.
find
)
released.
find
)
due.
def
=>โฆ
(by-name){}
ifโฆthenโฆelseโฆ
val
&&
,
||
,
==
,
<
,
>
,
<=
,
>=
,
+
,
*
,
-
,
/
,
%
Int
,
Boolean
,
String
var
, for
, while
Implement a simpler version of the Unix find
command (traverse a file system and print entries matching a rule).
2
)
released.
boids
)
released.
find
)
due.
boids
)
due.
โฆ=>โฆ
(function types)f(โฆ)โฆ(โฆ)
(currying)_
, โฆ=>โฆ
(anonymous functions)class
, private
, this
, override
f"โฆ$โฆ"
, f"โฆ${โฆ}โฆ"
(string interpolation)Explore emergent behaviors in bird-flight patterns by implementing a discrete-time artificial-life simulation.
3
)
released.
calculator
)
released.
find-hof
)
released.
boids
)
due.
calculator
)
due.
find-hof
)
due.
@main
package
, import
Any
, AnyRef
, AnyVal
, Nothing
object
(singletons)matchโฆcaseโฆ=>โฆ
Implement a mini-programming language for arithmetic expressions, complete with an interpreter (evaluator), an optimizer (simplifier), and tests.
This weekโs assignments include the first of three callbacks: a mini-lab in which you revisit and improve the implementation of a previous assignment.
In find-hof
, youโll refactor find
to remove redundant code and simplify the implementation. This sort of refactoring task is a common aspect of any software-engineering job.
4
)
released.
calculator
)
due.
find-hof
)
due.
huffman
)
due.
class C[T]
(generic classes)def f[T]
(polymorphic methods)(โฆ,โฆ,โฆ)
(tuples)requires
, ensuring
Option
Either
List
and
List
methods
FunSuite
, test("...")
, assertEquals
List
API.Implement a file compression and decompression utility using Huffman coding.
5
)
released.
anagrams
)
released.
callback-unguided
)
released.
anagrams
)
due.
[T <: S]
, [T >: S]
(subtyping)[+T]
, [-T]
(variance)Array
Vector
Range
, โฆtoโฆ
, โฆuntilโฆ
Seq
Set
Map
forโฆifโฆyieldโฆ
def f(x: T*)
sorted
groupBy
for
comprehensionsCopmute agnarams of idnviudial wrods and setnneces.
6
)
released.
scalashop
)
released.
anagrams
)
due.
callback-unguided
)
teams
due.
callback-unguided
)
proposal
due.
scalashop
)
due.
callback-unguided
)
due.
map
and reduce
.Implement common image filters, using parallelism to speed up computations.
Develop your independence, project-planning abilities, and code-reviewing skills by designing and implementing your own callback.
7
)
released.
pathfinder
)
released.
find-lazy
)
released.
October
)
released.
scalashop
)
due.
callback-unguided
)
due.
callback-unguided
)
checkoff registration
due.
October
)
due.
callback-unguided
)
checkoff
due.
pathfinder
)
due.
find-lazy
)
due.
Duration
API:
, {}
(block-based argument passing)In scope for the midterm: everything up to and including (weeks 1 to 6, including the lab).
Use lazy evaluation to remove the duplication between findFirst
and findAll
in find
and find-hof
.
9
)
released.
callback-unguided
)
checkoff
due.
webapp-rps
)
released.
pathfinder
)
due.
find-lazy
)
due.
webapp-unguided
)
teams
due.
webapp-rps
)
due.
webapp-unguided
)
proposal
due.
10
)
released.
webapp-unguided
)
released.
webapp-rps
)
due.
webapp-unguided
)
proposal
due.
Welcome to the unguided webapp lab! This is the final lab of the semester, spanning four weeks.
By the end of this week, you should have:
You can start working on your app as soon as you have a team and a proposal!
11
)
released.
November
)
released.
webapp-unguided
)
checkoff registration
due.
git
range-diff
,
send-email
By the end of this week, you should have:
12
)
released.
November
)
due.
webapp-unguided
)
checkoff registration
due.
webapp-unguided
)
due.
Future
-based computations in direct and monadic styles.By the end of this week, you should have a second, nearly-complete prototype implemented:
13
)
released.
webapp-unguided
)
due.
webapp-unguided
)
checkoff
due.
By the end of this week, your webapp should be complete:
webapp-unguided
)
checkoff
due.
December
)
due.