![]() |
CSE 143 Autumn 2000Homework 0Due: Electronic submission by 10 pm, Wednesday 9/27. Paper receipt due in quiz section on Thursday 9/28. |
This assignment will not be a big factor in your grade. But you should do it anyway. Only Part 5 will be checked (and graded generously.)
Starting a new course like this one can be daunting. You'll be learning a new programming language, and (possibly) a new set of tools to interact with that language. The first thing you should do is become comfortable with the tools you'll be using. That way, when you have to actually write bigger, more complex programs, you can spend your time thinking about the solution and not get bogged down with unfamiliar software.
The first thing you should do is become familiar with the course's web pages. The web is a primary means of disseminating course information. You are expected to look to the web for answers before you ask the staff, and to check it regularly for updated information.
Be sure you're pretty handy with some web browser. Then go to the course's main web page. Read all the information labeled as "required reading". You are responsible for this information - you are expected to know, understand and follow all the rules and regulations for this course.
Browse around the rest of the web pages, and get a sense for where everything is. When the time comes to find information fast, you'll want to have a general idea of where to look.
The newsgroup uwash.class.cse143.bboard is for general discussion about course topics. You should check this regularly. Feel free to contribute to the discussion and post questions, answers, or other course-related notes here.
You should have a UWNetID and regularly read mail sent to the address you've provided to UW. We will send mail to that address if we have an urgent announcement that everyone in the class should read. These messages will be archived on the CSE 143 web site.
Next are the programming tools. You are free to use any current standard C++ implementation, but if you're new to computing, you're probably best off using the IPL's setup: Microsoft Visual C++ 6.0 on Windows PCs. You'll get better support from the course staff, and this is the system that is used to compile your programs when you turn them in. If you haven't used Visual Studio before, look on the CSE 143 and CSE 142 web pages for tips.
Create a new, empty console application (File >
New... > Win32 console application
) and, in it, a new
C++ source file named bugs.cpp
. Type in the
following program, exactly as you see it here (but with a
different message if you like):
#include <iostream.h> int main( ) { cout << "Bugs everywhere!" << endl; }
Compile and run it. If you encounter any errors, fix them.
Here's another straightforward programming exercise. Give it a try.
Write a simple C++ program to convert Fahrenheit temperatures to Celsius. It should repeatedly prompt the user for a temperature in degrees Fahrenheit, and output the corresponding temperature in degrees Celsius. You should use C++ stream I/O (cout and cin; see text, Appendix A), not C's printf and scanf. The conversion is Celsius = (Fahrenheit-32.0) * (5.0/9.0). Here's a sample dialog with the program:
Please enter a temperature in degrees Fahrenheit:
72
72 F = 22.2222 C
Please enter a temperature in degrees Fahrenheit:
110
110 F = 43.3333 C
Please enter a temperature in degrees Fahrenheit:
18.0
18 F = -7.77778 C
After completing homework assignments, you must turn them in using your web browser. For this assignment, you should turn in the C++ program from step 4, above.