Homework 1: Choose one of the following 7 problems to solve. You
should
submit your solution to the PC Judge or UVA Judge for
verifying
the correctness. Due: Oct. 1 12:00AM
變數的型別及運算子的使用 (Java03.ppt)(Alg.ppt)(Al-Khwarizmi-1)(Al-Khwarizmi-2)
Homework2: Write a Java application to input a positive integer n
larger
than 2 and no larger than 2147483647, and to output the largest prime
less
than n. The homework should include the programs and the output
results. Due Date: Oct. 8, 12:00AM
陣列與迴圈的使用 (Java04.ppt)
Homework3: Write a Java application to draw
cards
100 times and to list all the experimental results and the total number
of
occurrences for each card. (You should use S, H, D, and C to stand for
different
patters.) The homework should be in MS-Word format to include the
program
and the output results. Due Date: Oct
15,
12:00AM
流程控制敘述 (Java05.ppt)
Homework4: Write a Java application to input
an
integer and test whether it is a 'perfect number'. A perfect
number
is defined as an integer which is the sum of its proper positive
divisors,
that is, the sum of the positive divisors not including the number. The
first
perfect number is 6, because 1, 2 and 3 are its proper positive
divisors
and 1 + 2 + 3 = 6. The next perfect number is 28 = 1 + 2 + 4 + 7 + 14. Due Date: Oct 15,
12:00AM
Homework5:
設計一Java程式,可輸入縣市別代碼及性別代碼,並自動產生一個正確的身分證字號。 (身分證字號真偽.
java) Due Date: Oct 15, 12:00AM
Homework 9: Write a Java
application
for users to input a sequence of charatcters from standard input
(System.in)
for checking if it has balanced brackets like { [ ( < > ) ] }. If
so,
output "Balanced Brackets!!"; otherwise, output "Unbalanced
Brackets!!".
You are confined to use Stack class, which implements Collection
interface,
with the concepts of generics, auto-boxing and auto-unboxing to push in
or
pop out an character for the checking.
Homework 11: Write a Java application for
users
to input a file name and a string. Output "not found" if the string
does
not appear in the file; otherwise, output the line number and offset of
the
string position.
Due Date: Dec. 3, 12:00AM
Bonus program: Write
a
Java Applet for users to draw or fill geometric items in any color, like rectangles, squares,
triangles,
rhombus (diamonds), circles, ovals, lines, arcs, polygons and strings. The applet should allow
users
to store and retrieve their drawings. Due date: Dec. 30, 24:00PM