1. Computer Science 151
An introduction to the art of computing
Lecture 1 - Introduction
Rudy Martinez
CS151
01/14/2018
2. CS151 Spring 2019
Course Admin
● Office hours: by appointment
○ I’m on campus everyday most of the day.
○ My office is in Farris Engineering Center room 3550C
● Exams: one in-class midterm exam + 1 final project
○ Midterm, either 3/6 (wed) or 3/20(wed)
○ Final is 5/10 (Friday) at 12:30pm to 2:30pm in this room.
● Homeworks: ~4 over the semester
● Grading split:
○ 60% homeworks, 20% midterm exams , 20% final project
3. CS151 Spring 2019
Course Admin
● Course announcements will be sent out via the UNM email
system
● Course materials (lecture notes, homework assignments,
etc) and other info will be posted on the class webpage [I
will announce when it is up.]
● Homeworks will be submitted via UNM mail system
4. CS151 Spring 2019
Course Text
UNM has free access to Safari Books Online, so no need to
purchase this book:
Programming in Python 3: A Complete Introduction to the Python Language
by Mark Summerfield
Publisher: Addison-Wesley Professional
Release Date: December 2008
ISBN: 9780137129294
https://libguides.unm.edu/Safari
There are also plenty of Python resources available on the
web.
5. CS151 Spring 2019
Policies: Class Attendance
Attendance to class is expected (read mandatory) and note taking encouraged. Important information
(about exams, assignments, projects, policies) may be communicated only during lecture time. We may
also cover additional material (not available in the book or in slides) during the lecture.
If you miss a lecture, you should find what material was covered and if any announcement was made. If
you have absences. It is your responsibility to find out what material you missed. I am happy to answer
specific questions regarding the lecture, but cannot go through all of the missed material on a one-to-one
basis.
That being said; I will not be taking attendance if you are not here I do not know generally.
6. CS151 Spring 2019
Motivation for class
● The objective of the course is to develop an
understanding of the relationship between computing and
problem solving.
● Computers are powerful tools, and being able to program
them gives you the ability to create powerful tools.
● If you are a CS major or minor you should be in
CS152.
7. CS151 Spring 2019
Policies: Academic Honesty
Unless otherwise specified, you must write/code your own homework assignments. You cannot use the web to find answers
to any assignment. If you do not have time to complete an assignment, it is better to submit your partial solutions than to get
answers from someone else. Cheating students will be prosecuted according to University guidelines. Students
should get acquainted with their rights and responsibilities as explained in the Student Code of Conduct
http://dos.unm.edu/student-conduct/academic-integrityhonesty.html
Any and all acts of plagiarism will result in an immediate dismissal from the course and an official report to the dean of
students.
Instances of plagiarism include, but are not limited to: downloading code and snippets from the Internet without explicit
permission from the instructor and/or without proper acknowledgment, citation, or license use; using code from a classmate
or any other past or present student; quoting text directly or slightly paraphrasing from a source without proper reference;
any other act of copying material and trying to make it look like it is yours.
Note that dismissal from the class means that the student will be dropped with an F from the course.
The best way of avoiding plagiarism is to start your assignments early. Whenever you feel like you cannot keep up with the
course material, your instructor is happy to find a way to help you. Make an appointment or come to office hours, but DO
NOT plagiarize; it is not worth it!
8. CS151 Spring 2019
Computing Facilities
● Labs will be in the basement computer lab.
● These computers run Ubuntu Linux 16.04 and have
Python 2.7 and 3.5.2.
○ We will be using 3.5 since 2 is deprecated
● These computers require a Computer Science Login, you
will get these in lab.
● You will have 24x7 access to these computers over the
semester by SSH
9. CS151 Spring 2019
Computer Science Account
● You will be assigned an account for the lab machines.
○ Please change the password!
10. CS151 Spring 2019
Labs
● Monday/Wednesday/Friday 10:30am to 11:30am.
● Monday/Wednesday/Friday 11:30am to 12:30pm.
● You may attend any lab.
● No Attendance is mandatory, however, this is dedicated
time for you to do your assignments with the help of the
teaching assistants to answer questions.
● Overrides due to time conflict;
○ I need your Name and UNM ID and I can provide the override. (Do NOT
email your UNM ID to me they get mad at me for this type of thing.)
11. CS151 Spring 2019
Why Linux?
● Still the premier scientific operating system.
○ Born out of the Unix OS
○ Free
○ Customizable
○ More secure from install than Windows/Mac OS
● As engineers you will most likely run in to linux as much
as windows
● The good news python is the same in any environment*
13. CS151 Spring 2019
What is Python? (from python.org)
● Python is an interpreted, object-oriented, high-
level programming language.
14. CS151 Spring 2019
What is Python? (from python.org)
● Python is an interpreted, object-oriented, high-
level programming language.
Interpreted means Python is
not the fastest language (your
programs aren’t compiled down
to native code) but they are
highly portable and easy to run.
15. CS151 Spring 2019
What is Python? (from python.org)
● Python is an interpreted, object-oriented, high-
level programming language.
But you aren’t forced to use
objects if you don’t want to!
Interpreted means Python is
not the fastest language (your
programs aren’t compiled down
to native code) but they are
highly portable and easy to run.
16. CS151 Spring 2019
What is Python? (from python.org)
● Python’s high-level built in data structures,
combined with dynamic typing and dynamic
binding, make it very attractive for use as a
scripting language or for rapid development.
17. CS151 Spring 2019
What is Python? (from python.org)
● Python’s high-level built in data structures,
combined with dynamic typing and dynamic
binding, make it very attractive for use as a
scripting language or for rapid development.
Don’t have to worry about
satisfying a type checker before
you are allowed to run your
program!
18. CS151 Spring 2019
What is Python? (from python.org)
● Python’s high-level built in data structures,
combined with dynamic typing and dynamic
binding, make it very attractive for use as a
scripting language or for rapid development.
Don’t have to worry about
satisfying a type checker before
you are allowed to run your
program!
It is relatively quick and easy to
put together working programs
for single-use tasks, such as
data analysis.
19. CS151 Spring 2019
What is Python? (from python.org)
● Python's simple, easy to learn syntax emphasizes
readability and therefore reduces the cost of
program maintenance.
No braces!
20. CS151 Spring 2019
What is Python? (from python.org)
● Python supports modules and packages, which
encourages program modularity and code reuse.
○ Scipy, scientific computing package optimized for speed and size.
○ Numpy, fast N-dimensional array package.
○ Matplotlib, comprehensive plotting package for python.
○ Pandas, data science package
○ Too many to list ...