So for this section, I'm gonna talk about sort of off start questions that people
posted on the forums. So I'm really glad people post all sort of questions and
discussions whatever. I'm sorry I can't talk about all of them. I just have to
pick some of them. And I'll made this kind of simple outline of what am I gonna say.
So the most popular topic in a sense was well what can I do after CS101? Where
should I go? What about this language that language, whatever and I'm not gonna
answer right now. That would be, I promise I will talk about HTML5 and phone
programming and Java and Python all that sort of things. I will talk about in last
week. We'll have an official section about that so I'm not talking about that today
so that's get [inaudible] questions. So all an out, I was gonna through, you know,
some like shows up, that's interesting, So Margaret Imber asks essentially how, how
do you produce this stuff and what kind of goes in to it. First of I should say I
feel like the technology, I mean, it works but I also feel like the whole Online
education areas so hot that I'm sure ten years from now will be just light years
better, But The way CS101 is produced and it works pretty well and it's actually
fairly simple. So, I write for each lecture, I just write straight HTML which
is the, the sort of standard language of web pages, pages And, and there's a thing
called CSS that is used kind of style with pages and stuff, the font, the color and
stuff. And then I'll just have JPEG and PNG images which are also standard and
I'll put those in the pages and that's what the, that's what the lecture
practically looks like. This program called OpenOffice, the free office suite
or recently, there's a new version called LibreOffice, Which is like, talk about
nerves coming up with not good product names. I think LibreOffice is not a good
name. Anyway that includes a free drop program and so that I just use a free
program to produce the rectangles and boxes and whatever. Just as inside I think
I will mention if you're ever pro ducing a document where you're trying to explain
something I mean diagrams are just so awesome/ And I think a lot of authors or
teachers feel sort of inhibited like oh well, I'm not gonna make very good artist,
not gonna look that great. And so there's inhibited to where they just don't do it
or their in words end up trying to paint a picture on words on what the thing is. And
I got to say. Just make a diagram. Just use your crummy arts skills and don't feel
uninhibited about being criticized and just make a simple little diagram and that
is much better. Anyway, that's what I do so that will end up with this fairly crude
looking diagrams I'll sprinkle all through here. So, just in, in terms of producing
the videos, I was thinking like sometimes we'll, we'll hear a story where someone
says oh well, you know, I have this tire in my car and it blew up and I was almost
killed and you're like oh, what kind of tire was it? And well, he'll say well I
don't wanna say it. That's lame, whatever. We should give credit or you know,
criticism or say so I'm just gonna say what technology would [inaudible] a little
picture. So to produce the videos. So this is what a typical set up looks like. So
I'm sitting on a laptop and I've got here the HTML page open. I'm just gonna end up,
obviously I'm just gonna scroll through it as I'm talking about stuff so then for the
sound, there is this company Blue that makes a bunch of microphones. These USB
microphones, just plug it in your computer and just we've been using that. Seems to
work pretty nicely and then the video of, of the talking head is just this Logitech
HD camera which also seems to work pretty nicely and also USB. So, you just plug in
here, And then finally, we use on the Mac, we use a software called ScreenFlow. This
seems that, it's pretty easy to merge together the picture of the desktop you
know showing the computer screen and merging the talking head and the sound and
then you know, I'm trying this and so I'm pretty happy with that. Alright. So yeah,
that's how we pro duce that I should say then Corsera has its own kind of internal
technology for how it does the exercises and whatever. That's. I'm sure that's
gonna change a lot and get better but it works. All right, another question, we
have Roberto Lopez asked about nested If statements and or logics or the natural
from last week is kinda a natural question, a great question really. It
turns out. That's the topic this week. You're gonna see all sorts of, it turns
out the syntax for that is this and our but that's in the so and as two ampersands
or this two vertical bars and that's, that's all through this week's lectures
and it'll come out more than you want on the on the weekly exercises so good
anticipatory question there. Also just nested statements put one statement inside
of another. Turns out it's kind of like end cause you end up having the first test
and the second test have to be true. So, anyway just check it out. Another question
was about a syntax, computer language syntax so moving, doing the waiver asked
questions about syntax, cuz one of the people mentioned it. So I know that it's
just CS101 sort of going from no programming to some programming. This
syntax maybe is very, it's very sort interface I like to use, it's kind of
annoying. I'll tell you all computer languages have this sort of fixed syntax
and ultimately I think it is not an accident that the fixed sort of rigid
syntax is ultimately an excellent way to communicate with computers. So honestly I
don't see that going away. You'll get used to it. I, you know, I work with computers
all day long, all sorts of different syntaxes and I never, I never feel like
oh, this syntax, oh this really interfering with my ability to express my
ideas. You know what, it's like at some point, I just got used to it, that's what
computers are and now I just work with the [inaudible] system very comfortable. So I
don't know if that's a good news. But that, that's my honest take on that, this
is syntax. Chris [inaudible] points out there's a system called Scratch that enab
les you to do some sorts of programming but without syntax where you sort of drag
and drop these little blocks around the represent logic. There's also some of
named as Alice system where you have these 3D things that kinda run around and that
also doesn't use syntax. So those are experiments in this kind of programming
space. Well, could you show people something about logic you know, let them
play around and learn about computers but not get [inaudible] syntax. Realistically,
my take is, is different from the Scratch [inaudible] system where my take is that
very introductory students can deal with a little bit of syntax and that is, that's
my that's my attempt at this problem. But these non-syntax systems are very also
popular and it's just, you know, you have to kind jump through a lot of hoops and
stuff to make things work without syntax. Also, ultimately I, I put my, my bet, on
you know, let's try to make some syntax work and then honestly it remains to be
seen which works better and obviously, it's just can be different for different
audiences. You know, if I had. First graders I would think yeah, maybe the
syntax is too much. Maybe I would try something else. But anyways, this is a
courage area of research, how that's going to work out Anonymous person asked what is
the real syntax for a Javascript portfolio? So I've mentioned here and
there, I should do this in the last section as well that, mostly we're doing
Javascript but you've got this sort of nick extensions on the front of them so at
the end, I'll need to expose what is, I can help with the. So All computer
languages have some syntax for this idea that you have a big group of things and
you wanted just essentially loop over them, You wanna do some operation for each
one. So here's a good syntax for that. Four pixel cone image, that's the syntax
we've been using. And actually that is pretty much the syntax that Java uses and
actually very close to the syntax that Pipeline uses and that's very popular
languages. It happens ironically this is not the syntax that JavaScript uses.
Javascript just by historical accident Doesn't have a good syntax for this very
common case. I think this one of the very unfortunate things about a Javascript. And
you may ask, well why they don't just fix it. It's a little bit, you know, once a
language is out there and millions of lines and codes have been written, they
can't just change so we'll have it [inaudible]. It's certainly like. If
England decides, you know, it really would be better if we all drop on the right had
inside [inaudible]. Yeah but they've got all of these roads and all these cars.
There's all the stuff in place where they can't just switch. And so, when I say
something is sort of stuck as historical accident, that's when [inaudible] it
happens with the Javascript. History was unkind. It has many nice qualities but
this one is terrible. So anyway, what is the syntax? So the syntax begins 4i or
this could be any variable you want, 4i in image. So you're gonna loop i over the
image but unfortunately in this case you would think i was gonna be the pixels
themselves but its not. It's an index into the image and then so then your next line
would have to say pixel = image square. So you take this index, you got here, used it
in the square back of an image and the neck gets you to pixel up. Anyway,
obviously this is not gonna come up for CS101 but that, that's the syntax. There's
a couple syntaxes in Javascript but that's, that's probably the last one. Now,
if you're writing a lot of code in Javascript, you know, I am obviously, I am
a little saddened by this kind of lame syntax but you know what, when are looping
over stuff is very common and at within the day, you could just get used to like,
okay well, that's what we have to do it and that's not gonna be a [inaudible]. You
could manage that. Alright, Another question I really liked from Dave Pittman
and Chris Posner was this question of well if you have a zero or one or whatever in
the computer how does it know. If its part of a JPEG you know, maybe its part of t he
red color or it's a, it's a letter in the e-mail or something. How, how does that
work? So the way it works, draw a little picture here, is you can think of RAM is
a, there are billions of bytes in RAM and the bytes are just laid out in an unmarked
uniform field. It just starts at you know, the zero byte runs all the way through the
end and there's no distinctions about anything. They're just all bytes. So, the
way it works is that the software which is manipulating RAM lays it out by area and
the software knows which byte it's gonna use for which purposes. So, let's say here
is this big bunch of bytes and so let's say I'm in a. You know a byte, you know my
example was it could be part of an RGB image or maybe it's a single type letter
so let's say it's a single type letter. So maybe, the program, it has all this RAM
and it all say well, these bytes here you know it's you know there's 10,000 bytes or
something. It says I'm gonna use these bytes to hold an e-mail that someone who's
typing in And so it's could sort do it by area. So it marks off that area and says
this is an e-mail here. So then as the user types in the letters of the e-mail.
So the letter a or something or letter t or something or whatever then maybe those
bytes gets set in here. It sets the 0s and 1s to be the number for the letter a or
the letter t or whatever and so then later when the software looks at this area it
knows, alright this is the areas set aside for e-mail so I know. To it I know to
interpret these bytes by letters. Or also you can imagine if the program said, okay
I'm gonna store the RGB image here. That's where I'm gonna use these bytes for. And
that's a little more complicated because it would even need to know what the
scheme. So, the scheme usually is gonna, is gonna have the red number followed by
the green number followed by the blue number. For each pixel so it'll be, it'll
sort of follow this three by two time pattern and this [inaudible] details. So
it would know that maybe that's a red number you know, zero to 55 and then it
would know that maybe that's the next red number. So the point here is that, if you
look at the chips, the bytes, it's just undistinguished. So, it seems to give you
know to hold. The way the software is able to work coherently, essentially having a,
a pre-plan about, for this area bytes is gonna be used and such and such way and
just might be consistent with that plan when setting the bytes and then later when
we [inaudible] back. You can also say in a way that the, the part disk, the flash
memory is also the same. Right at the, the hard drive likewise, it pretty much just
looks like a big bunch of bytes. And so the software would need to know oh,
something about other file like JPEG. Oh, I know that in that I stored the bytes for
RGBM image or, or something. It needs to have some plan so then when it gets the
bytes back, it knows how to organize. All right, So oh, sorry, it's our last
question. So sort of about the question of what does it take, what, what, what would
do you wanna do if you wanna be a CS major? Salvardor Diaz. So I'm gonna have
someone [inaudible] answer for this question. So the first thing that you
should know is that most colleges do not require, if you want a major in CS. Don't
have some requirement when you come in with programmability. So and for example,
it's Stanford. The Stanford CS106A course, it's an excellent course. It's fairly
difficult but there's an enormous amount of support, there's tons of office hours
and all those help so people have a lot of different abilities and all get through
it. That course requires no experience or whatsoever. So it'll show up and then that
is a full programming course. So, CS101 is not a full programming course, it's kind
of a sampler, I'll describe this more in the last week, 106A is a for real pretty
demanding really important question, ten weeks. So, What does this mean if you are
a pre college and you just sort of think about this? Well, one answer and I talked
to a couple of colleagues in Stanford about this. One answer is, well, you might
just kinda do well in Math and Science and English, whatever. Just courses that
colleges look at just to get in to college and all, that, that's maybe good
background goal. Now I'm gonna take that part a little bit and say. I don't think
it is that important in particular that you do well in Math and Science to take
CS. That's maybe partly controversial. Obviously Computer Science involves. Doing
some math and sort of organize logical thinking Like you know if you happen to
hate biology or actually even if you dislike calculus. I don't see that's being
a big for CS. I think computer science in some [inaudible] is what on you, you've
got in a real sense of what sort of, there is math and there is logical thinking but
I think it's a little bit a thing into itself. If someone has done very well with
calculus or very well in physics, I mean that's fine. I mean it just shows that
their you know, their brain is good at working at stuff and sure that's gonna be
useful for computer science. But I think it is more sort of the historical accident
that physics or in my high school calculus was regardless very important advance
thing to do Whatever. I mean its fine. If you get to use your brain and you practice
something you're interested but I wouldn't link it to a computer science exactly. So
what is going to help you with computer science? I'd say the most important thing
for computer science and not everyone agrees with this but I feel it's true is
programming experience like playing, and programming doesn't have to be some big
heavy weight thing but I think playing around with computers in a meaningful way.
Gives you a stronger intuition about how they work with the boundaries and
obviously CS 101 very much fits on this pattern. So there's many things that you
could do with computers that I think help sort of feeling those instincts. I think
the, the key feature is having some sort of real project, your typing and clicking
in the computer creating something that [inaudible] at have some visual upload
that you ca N. Change it in some way and then get slightly different output. I
think those are the, those are the key qualities. It's possible for someone to
just self motivate like get the book on whatever and then play around on your own
but I think that's, that's just difficult. In a sense this is why courses exist like
well, even if maybe you have the ability to play around with a robot or whatever,
it's just much easier if there's someone setting kind of a weekly case and give you
little goals [inaudible]. So that said, I'm just gonna mention a bunch of sort of
computer related things that I would think would be useful or if I was talking to
high school person who is interested in maybe doing computer science. Just so in
no particular order so there, there's a chip I showed earlier, the Arduino,
Arduino is set up for doing such a little art projects with little blinking lights
or switches, whatever sorts of physical thing. It's not software just down the
screen of your computer and there's a lot of blue books and kits or whatever.
Essentially to play around with the Arduino it's kind of fun. It has some sort
of a hands on feeling and it involves a little, a little bit of programming. So
that's it. Random thing, something in credit There is in the US. I don't know if
it's international. Not sure. There is a computer science high school course. It's
in Java. It's a fine class. There are lots of books and online resources or whatever
that I happen to fit in the material and some high schools have it but some don't.
I mean I think. That's why colleges realistically should not expect some prior
experience cause where, you could have great, you know, world's greatest high
school students but whether [inaudible] have it. Well high school people are
planning out for robotics is sort of like Arduino you know, it kind of a fun, hands
on, way to play around computers. I can't remember a couple of some sort of the
weaker forms spreadsheets you may have heard of spreadsheets, Spreadsheets
actually have in them a simple language for the Google spreadsheet than it is
actually a Javascript which allow you to write a little short bits of code that
they do really interesting in [inaudible] with data adding things up or computing,
you know, something like computing. So next time you find yourself in the
position where you got some big ton of data or, you know, part of your Biology
class or Club or something I would say I would be open to, oh, you know what I'm
gonna go read the docs and gonna try and use the spreadsheets to do this rather
than by doing this by hand or something. I think that's an example of pushing
yourself to use the computer. In something that looks like code but I think it's
beginning, it helps to fill out that scale set Just sort of make that stuff work.
Notice the one example is some games have a level editor that's maybe a kind of a
reduced form of programming but the level does have a kind of a logic to it and so
you could play out the level editor and then play it sort of yeah, yeah, yeah,
yeah, sure. I think that, that is getting you some insight about the. The formal
instruction of the computers So as I said, anything where you're, you're using your
brain and seen there was also doing adjustments, I think is, is a good
impression for doing something you could do. All right, So, thanks again for all
the people who are sending questions. Like I said, I'll have the, the What Could You
Do After CS101 will definitely be a, a last week topic. All right Take care.