Topic #1 – Intro, print¶
What will I learn?¶
- The short version:
How to write computer programs with python
How to write programs to solve problems
A little bit of how computers work
A little bit about what on earth computer science actually is
How to be a 21st century individual so you won’t be left behind
- The long version:
What prerequisites do I need?¶
Curiosity
A desire to learn a powerful new skill
A desire to distinguish yourself from peers in your discipline
Activity
Where have you encountered computer programs before?
Can anyone name an area of Science where they think having computer programming skill would be a bad thing? How about Social Science? Humanities? Art? Work with your neighbours.
Why are the course notes a website?¶
You’re going to learn to program with Python
A nice thing about Python is that it has a vast collection of libraries to do useful things
Most of those libraries are documented with something called Sphinx
The course notes are made with Sphinx
The idea: get used to reading material in this format. It’ll be useful to you
Moodle will be used for announcements and assignment submissions
How will this class work?¶
This class is going to be run somewhat differently from other courses you may have experienced at university
We’re going to be using a “partially flipped” classroom, with a “microlecture” format and lots of in class hands-on time
- There are a few reasons for this:
It’s been demonstrated that students from classes using the microlecture/work format outperform students from traditional lecture classes. The students are also report being happier and more engaged
Listening to a lecturer droning on for hours isn’t very engaging
You get better value for your tuition dollar (what can a lecture give you that a Khan academy video or a textbook can’t?)
A standard class works like this:
I lecture for one hour
You get bored 10 minutes in and start thinking about products you might like to buy on Amazon or what you’re going to watch on Netflix when you get home
I keep going
You keep daydreaming…
Our class will work like this:
You’ll be offered suggested readings every week
- You do the reading (or not, your choice… although I really really recommend it)
People that actually do the readings typically get 90+ in the course
You check out the YouTube videos
I give a short microlecture on a topic from the readings
I give the class a problem to solve, based on the microlecture
You work with your neighbours in class to solve the problem
I walk around and interact with the class. Answering questions, giving pointers, etc.
- I depend on YOU to interact with me
I will need your help throughout the lectures
We repeat this process until the time is up for the day
We’ve already done this once already, but let’s try it again:
Activity
Have a chat with the people sitting around you:
What are their majors?
Why did you come to StFX?
Why are they taking this class?
What do you hope to learn?
How do you think you will use what you learn in the future?
What should I bring to class¶
Curiosity
Readiness to do stuff, rather than just listen
- A laptop (if you want) or pen and paper
The weapon of choice of some of the greatest programmers in past generations
Just to be crystal clear: you do not need to bring a laptop to class
If you have one, and you’re keen to get the most out of the class, it’s worth considering
Is this class easy?¶
The quick answer is, it depends…
Quick Activity
Who here knows how to use a hammer?
Who knows how to use a screwdriver?
Who knows how to use a saw?
…
…
Who here knows how to build a house?
Each of the things you will learn are perhaps simple on their own, but using them together to achieve something is challenging
These topics really are going to be shockingly different from what you are probably used to. Very few classes can prepare you for the way of thinking that will be required for this class
Unfortunately, intro to CS classes do often have an unusually high fail rate
So I should be terrified?¶
No
- It’s actually not that bad, if you put in the effort
But that’s why we’re all here, right?
Real waring though: The class is dense and very accumulative, do not fall behind!
The good news is, you get to make mistakes
You get to see if what you did works or not
Most of this class will be you beating your head against your keyboard until you get it right
Not many classes or disciplines give you this luxury
- I really can’t stress this enough
Most of the time when you’re working on the course material you will be getting things wrong
The majority of programming is actually debugging
- Get used to making mistakes
This is a good thing
This is normal
I need help!¶
There are A LOT of resources to help you. We have Google, YouTube videos, email, Google, office hours, labs, Google, Google, etc..
Why did you just say Google so many times?¶
When a programmer isn’t debugging, they’re Googling their problems
This is so common that you can find an insane number of memes making fun of this
- I am going to tell you to “Google It” very often in this course
This is intentional
Independent learning is one of the most important things you will learn at university
Further, it will be your go to tool when you’re programming in the future
Can I write a program now?¶
If you have looked at get set up for CSCI 128, then yes
- Go to Google Colab and make your “Hello, world!” program
“Hello, world!” is traditionally the first program one writes in a new language.
print("Hello, world!")
You’re now officially a computer programmer!
Videos¶
- WARNING:
These videos are not a substitute for lecture or the course notes. They are supplementary.
These videos were NOT created for this course, but a similar class, so they’ll probably be handy
These videos are using the local interpreter. You will not see any Colab in them. They will still be super useful though.
These videos were made for Python 2 (but that won’t really matter for you. Most you’ll have to deal with is adding brackets to the print statements.)
For next week¶
Read sections 2.1-2.5 of chapter 2 of the text
Get your computer at home set up for CS 128