[Music]
>> Mamma who bore me Mamma who gave me No way to handle things
Who made me so bad Mamma, the weeping Mamma, the angels,
No sleep in heaven Or Bethlehem.
>> Mamma who bore me Mamma
who gave me Mamma the angels who made me so sad.
Mamma who bore me Mamma who gave me No way
to handle things who made me so sad.
Mamma the weeping Mamma the angels.
No sleep in heaven or Bethlehem Some pray that one day,
Christ will come a'-callin'.
They light a candle and hope that it glows.
Some just lie there crying for Him to come and find them
But when He comes they don't know how to go.
Mamma who bore me Mamma who gave me No way to handle things
Who made me so bad Mamma, the weeping Mamma, the angels,
No sleep in heaven Or Bethlehem.
[Applause and cheers]
>> Thanks, guys.
We are the cast of "Spring Awakening."
The show goes up in the Oberon
between November 30 and December 5.
Go to awakening at Oberon dot com,
that's awakening a-t Oberon dot com
for tickets and more information.
Thanks, guys.
Enjoy your lecture.
[Cheering, laughter and music]
>> Some things we don't talk about better do
without just hold a smile we're falling in and out
of love the same damn problem together all the while you can
never say never why we don't know when time
and time again younger now then we were before don't let me go,
don't let me go, don't let me go, don't let me go,
don't let me go, don't let me go picture, you're the queen
of everything as far as the eye can see
under your command I will be your guardian
when all is crumbling steady your hand you can never say
never why we don't know when time and time
and time again younger now then we were before don't let me go,
don't let me go, don't let me go, don't let me go,
don't let me go, don't let me go we're falling apart
and coming together again and again we're coming apart
but we pull it together pull it together, together again
[Music]
>> don't let me go, don't let me go, don't let me go,
don't let me go, don't let me go,
don't let me go don't let me go, don't let me go,
don't let me go don't let me go, don't let me go, don't let me go
[Music and applause]
>> So this is or was CS50.
My name is David Malan,
and I will be your instructor one last time today.
A word of thanks to the huge team this year that's made
everything quite possible.
This is a record size staff that we've had this year --
if you guys want to come on stage in the edge here,
full circle like the beginning of the term.
[Applause]
>> Only, only a few were able to skip class for this today,
but our team of TFs and CAs numbers 100 this year
for the first time in history,
so without them we certainly could not have made this
semester possible, and a huge thanks, too, to Barry and Kevin
and the Abos and Chris
and really everyone who's been working behind the scenes
to make everything here possible this year, and particularly
to those folks with whom you've gotten familiar on camera --
Jason in Section, Tommy and Walkthrough,
and my heartfelt thanks to Rob Bowden and Matt Chartier,
without whom we would not have this extraordinary team.
Allow us to take a look at the team
that was CS50 staff 2011 here.
[Music]
>> My heart's a stereo It beats for you,
so listen close Hear my thoughts
in every no-o-o-te Make me your radio And turn me
up when you feel low This melody was meant
for you Just sing along to my stereo Gym Class Heroes baby!
If I was just another dusty record
on the shelf Would you blow me off
and play me like everybody else?
If I asked you to scratch my back, could you manage that?
Like yea fucked up, check it Travie, I can handle
that Furthermore, I apologize
for any skipping tracks It's just the last girl
that played me left a couple cracks I used to, used to,
used to, now I'm over that 'Cause holding grudges
over love is ancient artifacts If I could only find a note
to make you understand I'd sing it softly in your ear
and grab you by the hand Just keep it stuck inside your head,
like your favorite tune And know my heart's a stereo
that only plays for you My heart's a stereo It beats
for you, so listen close Hear my thoughts
in every no-o-o-te Make me your radio And turn me
up when you feel low This melody was meant
for you Just sing along to my stereo Oh oh oh oh,
oh oh oh oh to my stereo Oh oh oh oh so sing along to my stereo
>> Travie McCoy: Let's go!
If I was an old-school fifty pound boombox (remember them?)
Would you hold me on your shoulder wherever you walk Would
you turn my volume up in front of the cops (turn it up)
And crank it higher every time they told you to stop
And all I ask is that you don't get mad at me When you have
to purchase mad D batteries Appreciate every mixtape your
friends make You never know we come and go
like on the interstate I think I finally found a note
to make you understand If you can hit it, sing along
and take me by the hand Just keep me stuck inside your head,
like your favorite tune You know my heart's a stereo
that only plays for you
>> Chorus: My heart's a stereo It beats for you,
so listen close Hear my thoughts
in every no-o-o-te Make me your radio Turn me
up when you feel low This melody was meant
for you Just sing along to my stereo Oh oh oh oh,
oh oh oh oh to my stereo Oh oh oh oh so sing along to my stereo
>> Bridge: I only pray you'll never leave me behind (never
leave me) Because good music can be so hard to find (so hard
to find) I take your head and hold it closer
to mine Thought love was dead, but now you're changing my mind
>> Chorus: My heart's a stereo It beats for you,
so listen close Hear my thoughts
in every no-o-o-te Make me your radio Turn me
up when you feel low This melody was meant
for you Just sing along to my stereo Oh oh oh oh,
oh oh oh oh to my stereo Oh oh oh oh (Gym Class Heroes baby!)
so sing along to my stereo Yeah
[Applause]
>> So Matt and Rob unfortunately could not be here today,
but we thought we would conference them in in absentia
with a little clip that both Rob and Matt prepared in advance,
so I give you Rob Bowden.
>> Hey, guys.
Good work!
[Applause]
>> Matt's was perhaps a bit more heartfelt for us all.
[Background voices]
>> Oh, hi!
Didn't see you.
My name is Matthew Chartier.
You might remember me from such CS50 events as "Section"
and "Quincy Office Hours."
Though unfortunately not able to join you in lecture today,
I still wanted to take the opportunity
to impart some thoughts as we near the end of the semester.
I said at the start of this year that CS50 is one
of those rare forces at Harvard College
that is sufficiently challenging, populous, elaborate
and fun to create a sense
of community throughout the entire course
and to provide an experience
that is not only useful but memorable.
My hope is that now, just a few months later,
you have a more personal understanding
of what I was talking about.
But as rewarding as CS50 was for me as a student,
it's been even more so as a member of the staff.
Over my last three years with the course,
I've had the opportunity to work with some of the most talented
and passionate people I've encountered throughout my
college career.
The dedication and personality
of this course's staff are what make all the ambitious
and unique things that we do possible.
And the friendship
and camaraderie I found among them has been one
of the highlights of my time at Harvard.
On that note, I'd like to thank the CAs, TFs, Glenn, Chris, Rob,
and David for all the work they've put
into making the course possible, both this year and years past.
It's truly been one of the most engaging
and rewarding experiences in my life,
and I'll remember it fondly.
I hope you will, too.
This is CS50, and I'll see you.
>> Matt Chartier.
So in just a bit our team of TFs
and CAs will be joining us downstairs for cake.
If you guys want to bring the preparations thereof,
Tommy can lead the way, I think.
In the meantime, a couple of announcements as we dive
into this wrap-up today.
So as you think about where you want to go
with your final projects after the CS50 fair,
know that in addition to opportunities like --
Tommy, follow them -- so in addition to opportunities
like the Hack Harvard Group, know too that the UC has begun
to support student projects that aim to improve the quality
of our experience here on campus,
so these slides will be online if you'd like to read up more
on this, but know that this opportunity
from the UC now exists.
And from SEAS as well, over January term this year,
if you are interested in learning a bit about design
from actual designers,
from a very well-known company called IDO,
know that this workshop will be a hands-on opportunity during
winter session, to do exactly that and be mentored
by some experts in the field, so head to that url if of interest.
We indeed have some cakes -- three cakes, no less.
Normally each year we try to come up with very clever slogans
to emblazon on these cakes.
Despite the confusion it creates with Shaw's,
where we have them made, this year we simply went with 0,
1 and 2, all of which awaits you downstairs.
Not as funny as it was in my head.
Okay. And now, the retrospective.
So 13-some weeks ago we dove
into this programming language we called Scratch
with which you hopefully had a lot of fun and began
to explore some of the fundamentals
of computer science and programming.
Well, for those submissions the teaching fellows reviewed all
of them way back when, and nominated, as is our tradition,
a few for some fun awards
of sorts whereby these projects will become immortalized
in the course's gallery online.
The one that the staff nominated
as the cutest Scratch project this year is by Brett,
and we will let it speak here for itself.
Allow me to play this year's cutest Scratch project
from 13 weeks back.
>> Teenage Mutant Ninja Turtles Teenage Mutant Ninja Turtles
Teenage Mutant Ninja Turtles Heroes
in a half-shell Turtle power!
They're the world's most fearsome fighting team Teenage
Mutant Ninja Turtles (We're really hip!)
They're heroes in a half-shell
and they're green Teenage Mutant Ninja Turtles (Hey -
get a grip!)
When the evil Shredder attacks These Turtle boys don't cut him
no slack!
Teenage Mutant Ninja Turtles Teenage Mutant Ninja Turtles
Splinter taught them to be ninja teens Teenage Mutant Ninja
Turtles (He's a radical rat!)
Leonardo leads, Donatello does machines Teenage Mutant Ninja
Turtles (That's a fact, Jack!)
Raphael is cool but crude (Gimme a break!)
Michaelangelo is a party dude (Party!)
Teenage Mutant Ninja Turtles Teenage Mutant Ninja Turtles
Teenage Mutant Ninja Turtles Heroes
in a half shell Turtle power!
>> Our second Scratch award for this year goes
to a new category -- the most inceptive.
Allow me to play this one here.
This one is interactive, so I shall play along as instructed.
[Slides read as follows:
"Dream Diving" created by Michael Hoffman.
"Welcome to the Future.
Extraction and Inception are Common Practices Here.
Your name is Stan and you work for the NSA.
The nation's most coveted security information has been
extracted from your mind.
You just find out who stole it
or else the entire world will be doomed.
Through your training and good fortune, you succeeded
in kidnapping one member of the extraction team.
You must now extract the names of the other members of the team
in order to arrest them and prevent the information
from landing in the wrong hands.
If you make mistakes, you must go deeper into the dream.
Good luck, and remember...
If you die in the dream, you don't wake up.
This is your hotel room.
The man in the corner is the member
of the team you kidnapped.
You must enter the dream and extract the names.
What did you want to do?
(a) drug him (b) go deeper.]
>> I shall hit "A."
[Slides read: Good, he fell asleep!
Now what? (c) Call your partners.
(d) Go deeper.]
>> I shall hit "C."
>> I shall hit "E."
>> I shall hit "F."
[Slide reads: Welcome to the first level of the dream (not
to imply that there will be more).
This is the spot where the subject got married.]
>> Why don't we cut it off there so leave it suspenseful.
We will link this online so you can finish the story.
And so finally, that was by Michael Hoffman --
finally by Blake Walsh is this year's most amazing,
a recreation of a classic game.
[Frog video game playing and Applause]
>> I actually practiced that this morning.
All right.
So we have some other awards that we typically bestow
and then honor on the course's Web site,
namely that for problem set 5.
In addition to recovering this year's photos,
recall that you were challenged
to then go find those folks somewhere on campus,
and if you did, we promised
to bestow upon you a fabulous award.
Well, we had one runner-up.
This was from -- you can guess whose section here --
Brian Zang submitted this on behalf of his section here,
but they only found a few of the staff members
and were definitely in the end vested by Lucas Fratas's section
with Neil Woo's section,
pictured here posing quite awkwardly with two
of our team members here.
But Lucas thought he'd be funny,
and when he submitted his photographs to us,
he wrote us the following note: "Hey, David, in anticipation
of this problem set, I spent the past several days snapping
photos, creeping TFs, I don't know, all of which were saved
by digital camera as jpegs on a 4-gigabyte compact flashcard.
Unfortunately I'm not very good with computers,
and I somehow deleted them all.
Thankfully in the computer world, deleted tends not
to mean deleted so much as forgotten.
My computer insists that the CF card is now blank,
and I'm pretty sure it's lying to me.
I attached a copy of my memory card to this e-mail.
Hope you can create a program to recover them."
[Applause]
>> So in problem set 6 recall there was a bit of a challenge
that of the big board to write the program
that used the least amount of CPU cycles
and the least amount of RAM.
Well, this is a system that gets gamed every year,
and it actually is a wonderful tool for recruiting
since those atop the big board are inevitably cheating
in some clever, technical way.
So here are the top ten from this year's big board.
Some of these times we are pretty sure are not
actually possible.
In particular you'll notice
that a certain Daniel Robinson somehow has the curious number
1.337 as his running time, so it turns out there are ways
to cheat the system, but what this will only make us better
at detecting such things next year.
But the top ten is certainly a nice place to be.
But we had another big board in problem set 7.
This one, too, attracts a big
of cleverness every year whereby you were challenged
to invest some 10,000 virtual dollars.
Curiously my penny stock has actually been performing very
well over the past several weeks,
but I was significantly outdone by Kenny.
So congratulations to Kenny
for being atop this year's Big Board.
Now, as we look ahead, what remains still even
after today is the CS50 Hackathon
for which you should have received an e-mail about RSVP'g,
and then thereafter is the true climax of the course
on December 9, a Friday, the first in the midst
of reading period, and this is this year's CS50 Fair,
and it promises to be bigger and better than ever.
And to get you excited and to get your friends excited
about dropping by the fair that day,
the teaching fellows have put together, along with the CAs,
a little video edited by our own Julia Middleman.
So I give you this year's CS50 Fair promo.
[Music]
>> Y'all ready for this?
[Music]
>> Every day I'm shuffling.
[Music]
>> Y'all ready for this?
[Applause]
>> So a word now about life after 50.
So you've spent the past several weeks exploring all sorts
of new tools and languages and environments
but otherwise tether to your own laptop
and particularly the CS50 appliance.
Realize, though, that there are all sorts
of directions you can go in after 50 both academically
as well as on your own even without future coursework
so that you can program on your own machines.
I would be remiss if I didn't point
out a new course that's being offered this spring
on mobile software engineering.
Though this will essentially pick up where CS50 left off,
spending about a third of the semester
on object oriented Javascript and web programming
in that space, as well as the latter two-thirds
of the semester on IOS programming, iPhones and iPads,
ultimately it's meant to be a software engineering course
on how to write good and better software, and particularly how
to collaborate with a partner.
And so you'll be encouraged to enroll in the class
with a friend with whom you'll be able to work
on the course's projects.
So more details can be found at courses dot cs50 dot net.
Now, as for using your own hardware and own software
after CS50, it turns out that the CS50 appliance,
more than just a CS50-specific tool,
is actually quite generalizable.
So even I and a lot of the TFs have started using our own CS50
appliance for writing code and working
on projects completely unrelated to CS50 simply
because it is the self-contained appliance.
It's the self-contained server that can run web code C-code,
Python, Pearl, PHP, all sorts of languages can be installed
in if not even there already, and so it allows you then
to have a nice clean sort of industry standard environment
with which to program.
However, with that said, if you're a Mac user,
know then that you can indeed continue using the appliance
in a manner similar to what you've been doing,
but if you want to take things to the next level
if you're running Snow Leopard or Lion, you can download
for free with some exceptions --
details are in the CS50 Manual --
a problem called Xcode from Apple,
which is an Integrated Development Environment, IDE.
It's sort of a much fancier version of gedit that allows you
to write code, debug code, version control code,
and a whole slew of other features.
That is specifically tied to Mac OS, but it's probably one
of the slickest IDEs out there.
We'll actually use it by nature of iPhone programming in CS164.
Free alternatives include Eclipse and NetBeans
and a simpler Code::Blocks, the last of which is C
and C++ specific but the first two are Eclipse,
and NetBean's quite popular, not only for Java,
which some of you guys might have experienced,
but also for CC++, PHP and all sorts of other language.
And then lastly there's this very popular toolkit called
XAMPP, which is free software
that includes an Apache web server,
the same thing the appliance runs, a MySQL installation,
PHP installation, and even PHP MyAdmin.
In short, if you don't want to use the CS50 appliance
for whatever reason, you can still install all
of those same tools very easily by downloading that free tool,
and it will set up your Mac for you.
And very similar options exist for Windows.
The only ones worthy
of distinction here are cygwin up there at the top.
This is a toolkit for free that you can download
that actually gives you gcc and gdb and a lot
of the command-line tools that we used this semester,
but it gives them to you in the context
of a Windows command prompt, so very similar
to our own terminal window.
And then Visual Studio for Microsoft is sort
of the de facto standard in the Windows world for writing code
for all sorts of languages.
But realize there's a nontrivial intersection among these tools
across the two platforms.
And for Linux, too, and if you're running Linux, frankly,
you probably have a bit more savvy when it comes
to configuring these things,
but almost all these same tools exist
in a Linux environment as well.
So realize, and certainly with the TF's or CA's help
after the term ends, if you want to reach out,
you can certainly continue on independently of CS50.
So where did we start?
So this is like week zero.
We started talking about algorithms and writing programs,
albeit in a simple context,
of making peanut butter and jelly sandwiches.
And we introduced this so that we could start thinking a little
more methodically, introduce the idea of pseudo code
and then silly things like indentation and constructs
like ifs and whiles that we can use in English
or statements here, but we wanted
to at least provide a mental model
with which we then proceeded to something like Scratch.
And Scratch, too, was hopefully fairly accessible,
but even by way Scratch were we able to talk about some things
that we kept using for 13 weeks --
loops and conditions and variables and all sorts
of other details that hopefully
in week zero actually came pretty naturally,
because it just made sense, and you drag and drop
and things fit together logically,
and so things just clicked.
Now, of course, weeks later,
things might have stopped clicking, at least not quite
as easily, and we introduced C,
in which we spent quite a number of weeks.
But if you think back to maybe your emotional
or visual reaction when you first saw this,
now at least hopefully you could kind of explain almost every one
of these lines or symbols one by one,
and some of them are intellectually interesting,
some of them are not.
Semicolons are not, but gcc thinks they are.
And so these same ideas though, from Scratch, persisted,
even as we proceeded through the world of gcc.
And here, too, so that we don't leave you
with any training wheels unremoved,
realize that we definitely got into the habit with C code
of writing Make Hello.
And Make recall, is not a complier; it's a build utility
and it just makes it easier
to write what would otherwise be very tedious commands to write.
So if you wanted to actually run gcc manually, back in week 1
or 2, you would actually write probably something like this.
And just from left to right, this is the program's name
of course, gcc-ggdb just meant include debugging symbols,
information, so that you can actually set line --
sorry, so that you can set break points and look
at the contents of variables.
std-c99 just means use the very latest version
of C. The next one means Warnings all,
yell at me for all possible things I might do wrong
and make them errors, so to speak.
Errors is worse than warning in programming, typically,
so that you can't even compile your code
if you have any warnings.
So that's all those things meant.
This of course was just the name of the file.
And then there were these things at the end,
so dash o hello just said name this thing hello instead
of a dot l at the default.
And then these things here -- dash-l dash-l dash-l --
were link flags that say link in code that someone else wrote
that someone else compiled, and merge it into my own program.
Because realize that the end game is
to actually output a file containing all sorts of 0s
and 1s like this, and these 0s and 1s are all
of course arranged in patterns and whatnot,
but you didn't write all of those 0s and 1s
that were generated; rather, you wrote Hello dot C,
someone else wrote Standard I/O dot C,
and by way of the header file and by way
of these linker flags you can tell gcc to merge those bits
into one single binary that you can run at the Command line
or in a gui, actually double-click.
But speaking of 0s and 1s,
a common question is folks prepared for quiz 1 this year,
was about these things called bitwise operators,
which are actually quite powerful,
and you'd explore things like this in more detail perhaps
in CS61 next fall, but bitwise operators do sort
of what that name suggests.
They operate on variables bitwise, so one bit at a time.
And the ones here we might use are these.
And notice, this is not a typo; this is not two ampersands
or two vertical bars; it's indeed just one.
This one means to take the bitwise AND of two bits,
and the next one means to take the bitwise OR of two bits,
and so al that means here is that if you take the bitwise
AND of two bits, well, 0 & 0 is going to equal 0;
0 & 1 equals 0; 1 & 0 equals 0; 1 & 1 equals 1.
In other words, you can essentially think of bits
as being Booleans, even though they are individual bits,
and so those same concepts that we talked about &ing and ORing,
also apply at the bit level here.
But they're more useful
than just doing simple arithmetic expressions
like this, rather you can use this thing.
This is something called xor.
And just so you've seen this one, too,
xor is an interesting one in that it's the exclusive OR.
So if you have two bits, a 0 and a 0, the xor of this is 0,
because xor says the output is 1 if 1 and only 1
of the two bits are a 1.
The other one has to be the opposite.
So that is not the case.
They are not exclusively different,
but this here would yield 1; this here would yield 1;
this here would yield 0.
So it's a slightly different pattern to the idea of & and OR,
for those who don't quite have line of sight.
So xor simply means only one of those bits can be a 1
for the output to be a 1.
And then lastly there are these other two operators shifting
whereby you can actually use an operator that looks
like that two-angle brackets pointing left and right,
to actually move the bits in a variable or in a number,
to the left or to the right,
effectively multiplying or dividing by 2.
Recall that in binary, the columns represent columns of 2,
so if you shift the bits it's like multiplying everything
by 2 or dividing by 2.
well, now, who cares?
Well, as an at-home exercise, a fun little trivia problem is
to ask, how can you actually exchange the contents
of two variables without using a temporary variable?
And that's a perfect question here since I only have two cups,
so let me pour some -- let's call it orange juice --
into this cup here, and let me pour some milk just
as we did a few weeks back, into this cup here.
And it would be a magical thing if I could swap the contents
of these two variables, these two cups,
without using a third variable called TEMP.
Now, these two I rehearsed at home -- and full disclosure --
didn't work out so well at home.
But the idea is the same.
So if I want to swap milk and orange juice, I can go ahead
and do this, and this was a nasty surprise last time --
that was too much of something.
Okay. Glad I did it in that order.
So now, milk was here, milk is now here.
I want orange juice over here, so -- oop, that's pretty good.
That's good enough -- magic!
So the at-home exercise is you can actually do this in code.
If you don't want to spend the variable,
the temporary variable, or you just want to be cool
and you do want to exchange the contents of two variables
without using a temporary variable,
you can use this caret symbol here,
which again is the xor operator, and it literally boils
down to this simple definition.
Given two bits that are different --
that are the same you get 0; given two bits
that are the same, you get 0; given two bits
that are different, you get 1,
so you can apply this caret symbol, this bitwise operator,
to every one in the bits from left to right in A
to the same bits that correspond in B,
and you execute these three lines of code and wala,
literally, you will swap the contents of these two variables.
Now, it's more just kind of a curious intellectual exercise
for our purposes since spending an additional 32 bits is not
such a big deal these days, but indeed it can be done.
And that actually worked out a lot better than I expected.
Thank you.
So we started with Scratch, we transitioned to C
and then we ended up towards semester's end
with the very user-friendly say web world,
in which the direction of software seems to be headed,
so we looked at html and made the simplest of html 5 pages,
and then we transitioned very quickly
to more interesting code, namely a programming language named PHP
so that you could actually generate strings
and content dynamically based on users' input.
And then of course, we introduced Javascript
so that you could also control the user's experience
client-side, and indeed today Javascript can even be used
server-side for very high-performing applications.
And so that was it, from week zero up to seek 12 you went
from Scratch, then to this low-level C language,
and my God, what you will see at the CS50 Fair, both done by you
and done by your friends, we don't doubt will impress,
as is the tradition each year.
So another tradition that we had toward the end
of the semester here, is to pit some students against staff
in a sort of contest of wits here, sort of Jeopardy style,
and so it's at this point that we need to take a few volunteers
from the staff and a few volunteers from the students
to come join me up here on stage for a little battling of wits.
Come on down, Carl.
Who else we got?
Come on here, 2, 3, we got room for 3 more.
Who are the shyer folks?
Come on, come on.
All right, let's go --
okay, here, because your friend's pointing
at you -- here, her, here.
All right, we'll stack the student team.
Come on up.
All right, who are our staff?
All right, if the staff want to take the end table there.
Students, if you want to line up here
and form two arbitrary teams.
We need let's see, one staff member
who could run the board -- Walkthrough Boy,
would you mind lending a hand?
This feels like your thing.
So we need a little scoreboard to be run here,
so in just a moment, if you want to go ahead
and ask these three teams for three team names,
and then we will keep track of their point values
on that, their Blackboard.
If you guys want to squeeze in --
yeah, just kind of kneel to the side as needed here,
as we get set, because using my new-found html skills,
I made a little something here with which we can do this.
That is the extent of my html skills here.
For -- here we go, wait for it.
>> This is Jeopardy!
>> And now we'll go jump immediately into week one.
So I apparently called for too many volunteers.
That's okay.
Maybe if we could just shuffle the chairs
down just a little bit,
and if you guys want to nudge your way in.
Staff name, what are we going
to call the staff here on the blackboard?
Team name?
>> [Inaudible].
>> Team Bowden.
>> Team Bowden it is, team --
all right, student number 2 in the middle here?
>> Thundercats.
>> Thundercats will be the middle team, and you guys here
on the end, you will be?
>> Zergrush.
>> What's that?
>> Zergrush.
>> Zergrush?
>> Zergrush.
[Laughter]
>> Am I the only one that doesn't know what this word is?
>> Star Wars.
>> Oh, then I'm not.
Okay. All right, so if you guys want to --
let's see, how many chairs do we have between --
if you want to kind of -- whoever you're friendliest with,
maybe share a chair there.
We're going to move immediately into single Jeopardy here.
We don't have all that much time to clear the board,
so we'll do just a few minutes for single
and for double Jeopardy.
In a coin toss before class of the Thundercats one,
which means you have control of the board.
What week would you like a question from,
and be sure when answering to speak into your mike,
and Tommy will be our judge as to whose hand goes up first
when answering a question.
[Inaudible comment from audience.]
>> Not much strategy is required for this game.
>> Week One, 1,000.
>> What's that?
>> Week One, 1,000.
>> Week one for 1,000 dollars, and your question is --
and again, the first hand to go up will be called on Tommy
to answer -- what is the maximum value
for a variable of type int?
Zergrush, I saw, two?
>> Which one of us?
>> You.
>> Any of you, just pick who speaks.
>> 2 to the 31 [inaudible].
>> So the student -- oh, by the way, these are your questions
that you submitted as part of problem set 8.
So that is correct, though the student was looking
for 2 billion, 147 million 483 thousand,647,
but I think we'll give it to them there for a thousand.
Well done.
You still have control of the board.
What would you like?
>> Let's go week 4 for 200.
>> Week 4 for 200 dollars,
and your question is what must you always do after malocating?
Thundercats?
>> Free the memory.
>> you must free the memory.
That is indeed correct for 200 dollars.
All right, you guys have control of the board.
What category would you like?
>> Week 2 600.
>> Week 2 for 600 dollars, and your question is going
to be, a string is actually?
Thundercats?
>> A pointer to a character.
>> Right, a string is actually a pointer to a character,
so another 600 dollars.
At some point we should do arithmetic.
And you're still in control of the board.
Time for a few more questions here in single Jeopardy.
>> Week 3 for 800.
>> Week 3 for 800 dollars.
Your question here is going to be in week 3,
why is linear search bad?
Zergrush?
>> Order of n when it could be order of log n.
>> That is correct, but speak towards the audience,
not toward Tommy.
>> It's order of n when it could be order of log n.
>> Excellent.
Very well done.
Up to 1,800 dollars, team Bowden is ever so slightly losing.
So we have time for one more question here
in single Jeopardy.
What would you like Zergrush?
>> Let's go week 4 for 1,000.
>> Week 4 for 1,000 dollars.
So team Bowden could move into second place with this question.
What is Emma's favorite kind of sort?
It's Emma's question.
Thundercats?
>> Bubble sort.
>> Incorrect.
That is I think minus 1,000, though.
[Applause]
>> Team Bowden's strategy is paying off.
But did your hand go up?
I think it did.
>> We were just stretching.
>> Team Bowden?
What is Emma's favorite kind of sort?
>> Burgers -- bogo.
>> What is there to confer about?
>> Bogosort.
>> Bubble sort?
That's what they just said.
>> Bogosort.
>> Oh, bogosort.
No, that too is incorrect.
Emma's favorite kind of sort is -- Emma, are you here?
Merge sort.
Several people know that her favorite sort is merge sort.
All right, and now we move on to double Jeopardy here.
So in Double Jeopardy point values are of course doubled.
Team Bowden will give you the choice of categories.
What would you like?
Weeks 5 through Rand.
Rand 4--
>> 2,000.
>> For 2,000 in the Rand category.
Name one function that it can be found in the CS50 library?
Why are your hands up last?
Thundercats for 2,000?
>> Get string.
>> Get string is correct.
Nicely done for 2,000.
All right.
And we have time for just a couple more questions
in Double Jeopardy now.
[Background inaudible voices.]
>> No, the Thundercats now have control of the board.
What would you like?
>> Week 5 for 400.
>> Week 5 for 400 dollars.
Week 5 -- you know,
I did implement some features here, so we can click that.
All right.
[Laughter]
>> I took CS50, all right.
Mel lock stores things in the -- question.
Thundercats again.
>> In the heap.
>> In the heap is correct.
We have time for one more question
in Double Jeopardy before moving to Final Jeopardy
at which point only people with non-negative values can proceed.
All right, Thundercats, last question in Double Jeopardy.
>> Week 7 for 400.
>> Week 7 for 400 dollars.
Your question is going to be here,
what did you building this week's pset?
Emma? Thundercats?
>> The P Shuttle.
>> Nope. Incorrect.
For minus 400.
Oh, into the mike, though, Zergrush?
>> Our own personal website and CRCD Finance.
>> The correct answer I'm afraid is up to Team Bowden.
[Laughter]
>> Would you know if it were?
No, I'm sorry, it was hashtable.
Minus
[Applause]
>> That's the answer.
So we now enter Final Jeopardy with Thundercats in the lead
with 2,200 dollars, Team Bowden with a lot of love and Zergrush
with 1,400, so we have time for these two here to duke it out.
In front of you is a piece of paper.
We will read -- the category is going to be difficult,
so go ahead and choose a dollar amount that you're willing
to wager out of your non-zero balance.
No, you do the dollar amount first
and then I tell you the question, or the answer
and then you tell me the question,
but we've not really been doing it that way anyway.
All right.
And now and Team Bowden,
if you'd like to play along, that's fine.
Oh, did we give them something?
>> I did.
>> Oh, Tommy has given you 400 dollars,
which means in theory the others should still be able to win.
All right.
So here we go.
Your question here is, convert 1.337 to binary.
[Jeopardy music playing.]
>> All right.
Gonna need your answers, almost there.
All right, Tommy, math time.
>> I can't do it.
>> All right, here we go.
So let's see, Zergrush was in second,
and you wagered all 1,400 dollars.
This will be easy.
So your answer was 010100111001.
Anyone playing along at home?
Which is correct for 1,400 dollars.
Now, Thundercats, who had 2,000, you wagered 1,000--
>> And 1.
>> And 1, in which case you'd win slightly more,
and so your answer was 1010011011,
which is not right, I'm afraid.
So that is a minus 1,000.
And Team Bowden, if they didn't write
down the answer as I read it.
[Laughter]
>> Let's give a round of applause then
for our student teams here.
[Applause]
>> So before we adjourn for cake downstairs in the Pub
with the CAs and TFs, let me say it has been an honor being
at the course's helm with you all and with our team
of 100 this year, and we'd like to adjourn today
with one final clip -- a look behind the scenes of CS50,
if we could one last time this semester, dim the lights.
[Music]
>> Y'all ready for this?
[Music]
>> Every day I'm shuffling.
[Music]
>> Y'all ready for this?
[Applause]
>> This was CS50, cake is served.