General Information
Professor: Micah Beck
- Min Kao 433
- mbeck@eecs.utk.edu
- Office hours by appointment. Send email.
Teaching Assistant: Ryhan Pathan.
Ryan's office hours in Min Kao 614:
Tues and Thurs 1:30pm to 2:30pm.
Class TT 11:10AM - 12:25PM in Min Kao 524
Lab Wed 1:25-2:15 in MK 421.
Grading is roughly 50% labs, 25% exam 1, 25% exam 2.
Lab grading policy will be set by the TA's. See their
web page for information.
Lab questions should be directed to the TA's first, and then me.
Lecture Notes
There will lecture notes for each lecture. These will be put on the
web with a pointer hanging off the class home page. The point of
lecture notes is to give you a hard reference for the things that we
talk about in class. The textbook is to be used as an additional reference.
All programs that I go over in class will also be online in a
directory for that class (~mbeck/cs360/notes/name).
The point here is that you don't have to try to copy
them down in class, as that's a waste of your time.
Labs
Besides the first week,
whose lab will probably take the entire session, lab attendance is mandatory
in the beginning, during which time the TA's will go over
general things that you need to know. After that, you may leave or
stay as you see fit. This is a very good time, however, to get an
early start on the lab, and use the TA's to answer questions.
The homeworks are where you are going to learn the most in this class.
They are going to require far more than 3 hours per week. Thus, you
will have to use evenings or weekends to get machine time. Work this
out.
Homeworks
Your TA's will tell you how to submit the labs.
You may talk with the TA, other students, or me about your
homeworks, but do the programming on your own. Copying other
students' code is considered plagiarism.
The Textbook, and Its Code
The textbook for this class is Advanced Programming for the
Unix Environment,'' by Richard Stevens.
It is a wonderful reference
book for Unix hacking, and it contains much valuable information. My
only complaint with it is that it goes so much into issues of portability
and Unix standards, that sometimes you get lost in the overload of
information. This happens --- after a while, you'll figure it out.
Reading the textbook is kind of like reading man pages: It takes a while
to figure out how to get information from it, but once you do, it becomes
an extremely valuable reference.
All of the code in the textbook is available online in the directory
~plank/cs360/book_examples.
This code was ported by a student a few years back, and I
don't know if anyone made use of it. I never looked at it. However, if
you are reading the book and would like to try its programs, that is the
place to look.
Unix Man Pages
Another valuable resource in this class are the Unix man
pages. These can be viewed online, by typing ``man xxx,''
where you want to learn about xxx. For example, try ``man
cat'' to learn about all the things you can do with the program
cat You will find that there are Unix tools for doing many things
you'd like to do. The routines sprintf, sscanf,
strcmp, strdup, atoi, and of course malloc will
all be of great use to you throughout the semester. Read up on them.
If you'd like to know if there is a man page on a certain topic, try
``man -k topic.'' Or read the man page for man....
Piazza
I'm trying Piazza this year. Go there and sign
up for this class. The point of Piazza is two-fold:
- It provides an online-study group where you can communicate with each
other, and with us (me and the TA's) if we're in the mood.
- It is where I will make class announcements.
TA's and Help
The primary place for you to receive help with your labs is during lab time and
during the TA's office hours. The TA's have office hours every day from monday
through friday -- use them!
Over the weekend, you're back on your own, and again you should solicit help
and support from your classmates. You may try to email the TA's, but again, they
may not respond. They have lives too.
Also, feel free to use piazza to communicate
with your fellow students.
I shouldn't have to write this, but history requires me to. While I love you,
and the TA's love you, this class is not our only responsibility during the
semester.
Similarly, you are taking other classes, so this class is probably not your
only responsibility. Think about that when you do things. For example, a few
years ago, a student resubmitted a late lab whose score was obviously going to
be lower than his first submission. He submitted it because he was proud of
finishing it, and wanted the TA to know. The TA, who was swamped with other
classes, simply regraded the submission and gave the student the lower score.
The student was outraged -- all he wanted was a pat on the back!! Who was
at fault? Everybody had good intentions. However, the student should have
used the proper channels -- if he wanted an "attaboy," he should have emailed
the TA seperately or gone through office hours. This may seem picky, but a
matter like this cost everyone time and emotional drama. Including me.
The bottom line is to think about your actions before you do them.
Help Each Other!
You are all brothers and sisters in this class. While I'm not the biggest fan
of interpersonal interaction and conversation, even I will admit that you learn
many unexpected and valuable things through interaction. This is both when you
are soliciting help and providing it. I encourage you to try to help each other.
My Pet Peeves
I go over these on the first day of class, but I figure it's time to write them down
so that you have reference material. Every teacher has his/her own style, and after
20+ years of teaching, I know mine pretty well. This list doesn't apply to all
teachers -- just me.
- Crosstalk in class: Evidently many professors don't mind this. I hate
it -- it both distracts and irritates me. I find it disrespectful, and I will be nasty to
you when I tell you to stop talking. I don't care if
you are talking about your labs or even what I've just talked about in class. Either
ask me, or wait until after class. I don't mind being interrupted with questions -- I
do mind when you talk with each other while I am lecturing.
- Laptops in class: Laptops (and iphones and ipods and ipads)
are distractions. You may tell yourself
that you're following along with my lecture notes, or taking notes yourself, but in
reality your mailbox is showing you that you have new mail, and the browser window
on facebook is simply beckoning you to see what your friends are doing and to reply.
I may ban them. I haven't decided. When your laptop is open in class, though, I
will assume that you're not paying attention.
- Email in the proper format: When you send me email, it should be in the
proper format. That means that is starts with "Dear Dr. Beck", and it ends with "Sincerely, your name."
You should capitalize, punctuate and spell properly. You should treat me as you would
an employer. Frankly, you should do this with all professors.
- "Dr. Beck, will xxx be on the test?":
What's on the test? Everything that's in the lecture notes. You don't need to ask me.
If I don't tell my "what's on the test" story in class, ask me to. It's a good one.
- "How about an extension or more points?":
There are people who believe "It can't hurt to ask,"
and therefore ask me often and gratuitously for lab extensions and points. Saying "no"
wears me out and irritates me. I am very sensitive to your time concerns. I am
especially sensitive to when things disrupt the lab schedule -- especially if it's
due to a mistake by me. I always attempt to make things fair. So don't ask just
because you think it can't hurt -- Pharaoh's heart will harden. Have a good reason.
My Non-Pet Peeves
- You are my children: I take a parental view of class. I am your father,
and you are my children. My wife says that this can be construed as being demeaning when
I say it, so I want to let you know that it is not. I take class and teaching very
personally -- I really want you all to work hard and succeed with this material.
Sometimes that requires tough love, but let it be known that I do care and
want you to do well.
- Non-class issues: This extends to computer-science/school issues that don't
directly concern this class. If you need advice about which classes to take, how to
search for jobs, which jobs to search for, how to manage your workload that has gotten
out of control, email me and schedule a meeting. I've been here at UT for nearly 20
years -- I have a lot of experience and knowledge and am happy to share.
- Class participation: Although I get all bitchy about crosstalk, I very much
like class participation. If you have questions, ask them. They may seem stupid -- they
may even be stupid -- but
I won't treat them as such. If you're lost and confused, say so.
I also don't mind you being smartasses (so long as you realize that as you give, you may receive).
There are times were I deserve to receive some
jibes from you...
Commenting Your Code
You will be graded on commenting. Something like 15%. You should
comment your code by blocks of comments at the beginning of your
files, and before subroutines. Variables should be commented
inline. You may also want to comment large blocks of code.
You should not comment with a ``running commentary'' to the right
of your code, because that is often useless, hard to maintain, and
disconcerting. I have seen comments like the following:
if (i == 0) { /* If i equals zero */
return; /* then return */
} else { /* otherwise */
exit(1); /* exit with a value of one */
}
The above is an extreme example, but don't let it happen to you.
Here's an example of what I would consider a well documented program:
#include <stdio.h>
/* sumnsquared.c
Jim Plank
August 23, 1998
This program prompts for and reads a value n from standard
input, and then calculates and prints the sum of squares
from one to n. It uses a for loop instead of using the
closed form expression.
*/
main()
{
int n; /* The value */
int sum; /* The running sum of squares */
int i; /* An induction variable */
/* Prompt for and read in a value of n */
printf("Enter a value n: ");
fflush(stdout);
if (scanf("%d", &n) != 1) {
exit(1);
}
/* Calculate sum for each value of i from one to n */
sum = 0;
for (i = 1; i <= n; i++) sum += (i*i);
/* Print the final summation */
printf("%d\n", sum);
}