I know this will get fixed sometime. Probably by tonite.
Until the buttons are functional you can to send me your assigned work question use by CSUSB.edu account with id 'rbotting' and include
CS202/Qnat the start of the subject. Include the chapter number and pages number...
You can send me a contact message by using the same address but please put CS202 at the start of the subject.
2009-03-25 Wed Mar 25 09:34 Grading done
I finisihed grading the final, and unless you can find an error
these will be the grades for the course.
Table
| Distribution | A/A- | B+/B/B- | C+/C/C- | D+/D/D- | F |
|---|---|---|---|---|---|
| Frequency | 6 | 12 | 5 | 0 | 3 |
After including all the seminar reports, many people had got the maximum 300 points. It is no longer possible to get points for CSCI201 by writing up seminars.
The final exposed weaknesses in many people's understanding of functions. This is where I will be starting CS202!
2009-03-23 Mon Mar 23 10:04 Prefinal grades posted
I've posted all the scores and grades that I know about in
[ grading/ ]
as usual. Let me know about any errors.
The grade for the course depends critically on the final.
Don't forget that you should bring a calculator, a single sheet
of 11><8.5 inch piece of paper with notes one it, and some pencils and an eraser.
2009-03-20 Fri Mar 20 18:17 Questions for class 20 posted
[ 20.html ]
The final is at the usual time, in the usual room, for 1hour 50 minutes on Tuesday.
Best of luck...
By the way -- I am not returning the final projects. They will be filed with the finals. You can visit my office to review the grading if you wish.
2009-03-19 Thu Mar 19 13:01 class 20
We developed to programs to calculate
See
[ h.cpp ]
[ h2.cpp ]
2009-03-16 Mon Mar 16 12:27 Grades posted and a common mistake in the last quiz
The grades are in
[ grading/ ]
(the usual place).
I made a mistake in suggesting initializing vectors like this
vector <int>daysInMonth = {31,28,31,30,31,30,30,30,31};
It does not compile. But it does work with an array:
int daysInMonth[] = {31,28,31,30,31,30,30,30,31};
There is more in the answers to question in
[ 18.html ]
last classes page.
The commonest error in the quiz was in the for-loop that output the vector. If you want to do something to every item in a vector v then you need an int variable that starts at 0 and goes up to the last valid subscript. This is v.size()-1. There are two common for loops that do this
for(int i = 0; i < v.size(); i++)
for(int i = 0; i <= v.size()-1 ; i++)Only the first fitted with the given (unblanked) code.
Hint: make sure you know how to visit the same items backwards. Exercise ....
for(int i = _____1______; _______2_______; ________3_____)
Tomorrow [ 19.html ] we will wind up arrays and vectors and I will demonstrate "Test Driven Programming" to develop a class Sample.
2009-03-10 Tue Mar 10 17:03 Strange square roots in the lab
These were caused by omitting a "return" statement. Here is the rule
that makes functions work: Void functions return nothing. Non-void
functions must return something of the right type:
double sd()
{
return sqrt(variance());
}
Tuesday's class is about a simple data structure: A linear collection of similar objects number 0,1,2,3, ... with varying size. We use them a lot. See my notes [ vectors.html ] for the basic facts and a simple example. This example is the basis for tomorrow's lab work.... which will revisit the techniques for calculating statistics of a sample of numbers.
I will answer you questions on vectors on Tuesday and plan to demonstrate some live coding in class. We will also have a SOTE. I hope to also have time to do a mock quiz/exercise.
The next quiz will be a "fill in the blank" quiz or "cloze procedure" . I will give you a working program that has some pieces of code that have been replaced by blanks. You have to fill them in. There will be points for syntax( will it compile) and semantics(will it run).
2009-03-06 Fri Mar 6 15:03 Answer for class 16 posted
[ 16.html ]
Grades before lunch Monday, Inshallah.
2009-03-03 Tue Mar 3 15:03 Answers posted for 15
[ 15.html ]
Next --
[ 16.html ]
with a project iteration due and a quiz on how functions work.
2009-03-02 Mon Mar 2 13:03 Grades posted and Tuesday
The grades
[ grading/ ]
have been posted ... and the error in the total possible for
lab06 has been fixed.
We will be doing exercises on functions in class [ 15.html ] tomorrow. To prepare study sections 6.7 to 6.10 in chapter 6 of the text and write down one question for me to answer. One question has already been answered.
Please note the following CHANGE OF SCHEDULE:
2009-02-27 Fri Feb 27 10:02 Change of Schedule
I don't like breaking the sequence in a text book, but I think it
is more important for you to learn about "vectors" than about "recursion" -- we
normally cover recursion in CS202. People need "vectors" for their project.
So I am making changes to classes number
[ 17.html ]
where I will be adding a special handout to replace section 6.19..6.21 in the text. Also
get a new copy of
[ schedule.html ]
the schedule for this class.
2009-02-25 Wed Feb 25 16:02 Questions answered on the web
I've placed answers to your question in
[ 13.html ]
and look forward to getting questions on C++ libraries and C++
functions in
[ 14.html ]
(next class). Don;t forget that you get points for any project 7
and full points if it has a class and is printed/tested code.
2009-02-23 Mon Feb 23 14:02 Latest Grades posted
Corrected quizzes+ answers+ projects will be returned on Tuesday.
Some people need to rethink how nested for loops work. As in all these exercises and debugging it is a matter of taking each instruction and following it as if you were the computer, and not guessing what the programmer wanted.
Bring a question on the reading: [ 13.html ]
The [ lab07/ ] is ready and involves developing a simple statistics filter program, step by step.
In the next step of your project -- I will expect to see a print out of code with a main program testing a relevant class for your vision. See comments on returned projects.... due on Thursday.
2009-02-21 Sat Feb 21 08:02 Check out seminars
5 points for attending one of these and giving me a short (short!) report at the
next class. See my
[ ../plan.html ]
for dates and some times.
2009-02-19 Thu Feb 19 13:02 Do-While Examples
Found these:
[ dowhile.cpp ]
(bug),
[ dowhile2.cpp ]
(runs but a joke).
2009-02-18 Wed Feb 18 08:02 Example of scoping and formatting
A couple of new examples to try out....
[ scopes.cpp ]
and
[ ../examples/formats.cpp ]
(for example of using left, right, set precision, etc....)
2009-02-16 Mon Feb 16 09:02 Start of second half of course
The grades for the first 10 weeks have been posted
[ grading/ ]
, please check for errors.
Study 5.1-5.4 on the for loop and bring one question on paper to class on the reading. For loops are the commonest loops in C++ and their is a quiz coming on them....
Then we will study the other control structures and then Boolean (or logical) expressions... Check [ schedule.html ] for the plan for the rest of the quarter.
If you want bonus/make up points, check the schedule of seminars [ ../seminar/ ] since we have some new ones posted.
2009-02-11 Wed Feb 11 17:02 Ready for class 10
I've posted the answers to your questions -- plus some example code
inspired by them. Enjoy.
On Thursday I expect a question on the end of Chapter 4 and the next iteration of your project. There will be a quiz testing your understanding of control structures.
2009-02-09 Mon Feb 9 10:02 Grades posted and Tuesday Class
The next class
[ 09.html ]
reviews some classic algorithms which will be
reinforced by
[ lab05/ ]
the next lab.
Bring me a question on the reading...
2009-02-08 Sun Feb 8 15:02 Questions answered
I have added questions to
[ 08.html ]
along with my answers and examples. Also I'm working on two new
electronic handouts:
[ string.html ]
and
[ files.html ]
to help some people with their projects.
2009-02-05 Thu Feb 5 07:02 YouTube Objects vs Classes
This robotic tutorial
[ watch?v=IBpZBI_8QAE&NR=1 ]
may help... Let me know!
2009-02-04 Wed Feb 4 13:02 Questions and grades online
I've answered your question (mostly online) in
[ 07.html ]
and also in
[ FAQ.html ]
the "Frequently Asked Questions" file for CS201.
I have also corrected and extended the [ grading/ ] data.
Next class [ 08.html ] is about control structures.
Don't forget to bring a printout of your project to get advice and points. At this stage I'll give 100% for any honest attempt, even if it is full of compile errors.
Also: bring one question for me to answer on section 4.1 to 4.7
2009-01-30 Fri Jan 30 16:01 Grades posted
If you go to
[ grading/ ]
and input your 3 letter key you can see your scores and a grade
based on the work before the last day to drop.
I'll get the more detailed stats up some time real soon.
2009-01-30 Fri Jan 30 14:01 Class 6 feedback and Next Project
I've expanded the notes
[ 06.html ]
on interfaces and implementation in response to your many questions.
I've graded the quizzes, projects, and questions and am looking good to publish them by Monday afternoon. Most people did well. Some people added before they multiplied. Some people guessed wrong. Some people used an old value of a variable rather than the latest value.
You can collect all your graded work from my office, if I'm there. Check my [ plan.html ] for when I'm away. The rest of the time, between 10-3pm: Knock.
Every body who handed in any project got 100%.... but next week, on thursday, you must hand in a printed listing of a C++ program for your project to get 100%. No more written projects: I want typed, editted, compiled, tested, and printed code. (gedit has a print button that works ok). It can have errors. I will help fix them.
Key point, next week: input a new ".cpp" file, compile it, fix what you can, run it if possible, and on Thursday morning: HAND WHAT YOU'VE GOT to me at 12 noon. If it is late you get 0%.
Your printed code should have your name in it. It should have a comment saying what your vision was, and what this program actually does.
Warning: Don't work at the last moment -- things always break down and you will lose more by being late than by handing in a listing with a small mistake.
Hint: download [ project.cpp ] and edit it to fit your project.
Advice in [ projects.html ] , I hope it helps.
2009-01-28 Wed Jan 28 14:01 Adding to Notes on class 5
I'm adding questions and answers to
[ 05.html ]
and have already improved the "Counter" class.
I also found an older and simpler example coding of
[ counter.cpp ]
that I wrote for my UML handout
[ uml.html ]
, enjoy!
2009-01-28 Wed Jan 28 10:01 Changed content of future quizzes in schedule
I've changed the Quizzes for February 5th and 12th:
Tomorrow on Thursday the 29th of January the topic will be variables and arithmetic and you should bring a calculator.
Also a question on the reading -- plus the lates iteration of your project.
2009-01-23 Fri Jan 23 13:01 Grading done and online
Go to
[ grading/ ]
and input your 3 letter keyword. You should be able to see the
grading so far. Your scores are on the line with three asterisks (***).
Let me know if you detect an error.
Note: these have been posted early because I have a busy Monday ahead of me.
90% of the projects are feasible. One unsolvable problem in CS201 is not being able to input or output unusual characters -- foreign alphabets (UNICODE) and mathematics. We are pretty much limitted to ASCII:-( I wrote [ test.Unicode.cpp ] to check this out with disapointing results.
Another difficulty is when the solution depends on a data base of information -- for example: baseball statistics. Here we will have to fake it using internal data in an array or possibly learn to do files 10 weeks early:-)
That said -- you all have great ideas.... all we have to do is pick ones
that can be simplified down to a series of simple steps like this:
2009-01-23 Fri Jan 23 09:01 Finished preparing study guides for Tuesday and next Thursday
I've improved
[ 05.html ]
(next Tuesday)
and
[ 06.html ]
(Next Thursday)
and you should read each one
before studying the readings in the text for that class.
Now on to grading:-(
2009-01-22 Thu Jan 22 13:01 Program developed in Class 4
In class we developed the following program
[ monday.cpp ]
that inputs two numbers and outputs their product. The code was written
in a hurry and should be improved... enjoy.
2009-01-21 Wed Jan 21 19:01 Ready for next class
Please use
[ 04.html ]
as a study guide and a reminder of what you should bring to class.
(Like a question on the readings and the second iteration of your project)
There will be a quiz at the
end of the class tomorrow that will cover how simple programs work
and what make a program more readable. You may use a calculator
and a single sheet of 8.5><11 in paper as a cheat cheet. The answers
will be written on the quiz.
2009-01-21 Wed Jan 21 11:01 Change to schedule -- Second Quiz
The second quiz (next week) will not be about classes and objects as I thought
but go over variables and arithmetic. You will have to find
syntactic and semantic errors in a program.
2009-01-19 Mon Jan 19 17:01 Projects etc graded...
I've graded the project visions. If you gave me one, then you got
100% of the possible 5 points.
Some projects would need access to the inner working of the operating system which is 400/500 level work. SOme need to read and write files of data -- and this is really part of CSci202. These also tended to use ideas that I had planned to cover towards the end of the course -- arrays and vectors. In these cases I've suggested rethinking the vision. No points were lost however.
Perhaps I should have spelled out that CSci201 is only covering prgrams that read what the user types and calculates results that are put on the screen:-(
I've fixed [ lab02/ ] ready for Tuesday afternoon. I'm going to type in some answers to some questions into [ 02.html ] and ready for you to review when you have time.
Prepare for Tuesday by studying sections 2.1 to 2.5 inclusive, trying the
review questions. See
[ 03.html ]
for details. And don't forget to bring
See you 12noon Tuesday 20th.
2009-01-14 Wed Jan 14 14:01 What to bring to class on Thursday
Thanks for putting up with chaos on Tuesday. Things will get
better.... inshallah.
On a piece of paper write your name, a question on chapter 1 of the text, and your vision of your project:
To help _______ do ____________
See [ 02.html ] for details.
Remind me to handout a form you need to take home and fill in for next Tuesday.
Meanwhile: I am working on the next lab (Tuesday) and the notes for Tuesday's class. I will announce when they are frozen, ready for Tuesday.
2009-01-12 Mon Jan 12 15:01 Outlines of classes ready
I spent the weekend inputting the outlines for all 20 classes.
I will be adding information to them to create study guides. Answers to some questions
will be added after class.
I was able, today, to upload the data..... Enjoy.
2009-01-07 Wed Jan 7 12:01 Many small changes made to projects and labs
I've just revise the instructions for the first laboratory and the notes on the
[ projects.html ]
for this class. I may be going back to them.
After lunch I'll be working on study guides.
2009-01-06 Tue Jan 6 06:01 Schedule change
I've shifted the grading load from Wednsdays to Friday...Mondays
in the schedule. As a result projects are due on Thursdays, Quizzes happen
on Thursdays, and Labs on Tuesdays.
Looks like I'll get grades posted on Monday afternoons!
2009-01-05 Mon Jan 5 14:01 Syllabus and Schedule almost ready
If you have time please check
[ syllabus.html ]
and
[ schedule.html ]
for bloopers before I print lots of copies tomorrow.
2008-12-30 Tue Dec 30 09:12 Added readings and topics to schedule
2008-12-24 Wed Dec 24 15:12 Starting to update site
Got the right dates in
[ schedule.html ]
and then fix the events, grading, notes, etc.... and see you on the 13th of January.
2008-03-20 Thu Mar 20 10:03 Preliminary Final Grades Posted for Winter 2008
I've posted my first final and course grades
[ grading/ ]
for you to check. They may change if any errors come to light
or bonusses are earned.
Currently we have
Table
| Distribution | A/A- | B+/B/B- | C+/C/C- | D+/D/D- | F | W |
|---|---|---|---|---|---|---|
| Frequency | 5 | 11 | 2 | 2 | 1 | 1 |
If you have scored less than 300 points prior to the final you can make up these points by attending seminars in the labs on Friday 21st and getting an essay -- one per presentation -- to me by EMail, or into my dept office box -- by 12noon on Monday.
Some previous items removed or redacted
2008-02-13 Wed Feb 13 10:02 Questions on functions etc answered online + project feedback
I've posted the answers to your questions in
[ 11.html ]
and have graded your quizzes. Nearly everybody got the correct output.
YEAH!!!!!!
I've also started grading you projects. Here are some common errors
that you chould check you code for now to get the jump on the next iteration
of this project. Note -- these are nearly all examples of intelligently
jumping to a completely false conclusion.
Table
| Basis | Guess | Correct |
|---|---|---|
| Because everything else I do is easy | This should be easy | Programming takes a lot of time, care and attention to detail |
| I'm in a hurry | I'll skip writing an algorithm it will save time. | You will get lost and confused when you don't plan. |
| For loops can declare a varible "for (type name = ..." | While loops can also do this | They can't. |
| Semicolons are at the end of statements | They can't be inside a for loop: "for(...,....,...)...". | They MUST be in a for loop: "for(...;...;...)..." |
2007-12-06 Thu Dec 6 18:12 Most Preliminary Grades for Winter 2006 Posted
Table
| Distribution | A/A- | B+/B/B- | C+/C/C- | D+/D/D- | F |
|---|---|---|---|---|---|
| Frequency | 4 | 8 | 3 | 1 | 4 |
I hope they help..... even if I feel it is always better to develop
one's own cheat sheets....
2007-11-15 Thu Nov 15 13:11 PI and Books on C++ in the library
This is in response to a lunch time meeting with a student.
Books on C++ can be found in the library with call number
QA76.73.C153
(PI): The best way to get π, e, etc into your program is to do this
#include <cmath>
const double PI = 4.0*atan(1.0);
const double E = exp(1.0);
const double ROOT2 = sqrt(2.0);These formulas automatically supply an accurate value without you having to type lots of decimal digits. By putting them outside of all the functions and classes you request that they are evaluated before the program starts running.
. . . . . . . . . ( end of section CS201: Introduction to Computer Science) <<Contents | End>>
Abbreviations