Computer Science 433
Programming Languages
Fall 2014, The College of Saint Rose
This problem set consists of some relatively short programming tasks and other questions. You may work alone or with a partner on this assignment.
Langauges on mogul
This assignment will ask you to write programs in four languages: C, C++, C#, and Java. Please make sure all programs run on mogul. In case you never knew or have forgotten, here is how to compile and run a program in each of these languages (using examples from the late penalty calculators in the shared area).
To compile:
gcc -o late late.c -lm
Note that -lm is needed only if linking with math library functions.
To run:
./late
To compile:
g++ -o late late.cc
To run:
./late
To compile:
mcs Late.cs
To run:
mono Late.exe
To compile:
javac Late.java
To run:
java Late
Questions and Programs
All programs required are to be treated as "Practice Programs" in terms of collaboration and grading. You are welcome to discuss them with your classmates, and I will grade only on correctness, not documentation, style, etc. Of course, you should still make sure your name is in every file you submit! Unless otherwise specified, all programs should be included in your submission and you should make sure they run on mogul.
Submission
Before 11:59 PM, Wednesday, October 29, 2014, submit your work for grading. Create and submit a single archive file (a .7z or .zip file containing all required files) using Submission Box under assignment "PS7".
Grading
This assignment will be graded out of 25 points.
Feature | Value | Score |
Question 1: computing addresses | 4 | |
Question 2: Programming Exercise 5 programs | 6 | |
Question 2: Programming Exercise 5 explanation | 2 | |
Question 3: Programming Exercise 6 programs | 3 | |
Question 3: Programming Exercise 6 results | 2 | |
Question 4: Programming Exercise 7 program | 6 | |
Question 4: Programming Exercise 7 explanation | 2 | |
Total | 25 | |