Java Programming

Location: Room 223A, 德田館
Time: 0900 ~ 1200, Saturday and Sunday


``Java is C++ without the guns, knives, and clubs.''
-- James Gosling, co-inventor of Java (1955-)

Instructor information

Wi-Fi Access

Recording Classroom Lectures Policy Recording of classroom lectures is prohibited unless advance written permission is obtained from the class instructor and any guest presenter(s).

Objectives

This course is designed for the students who want to learn Java but have no programming experiences before. We will start with the very beginning of program design and fundamental concepts about programs and machines. You are expected to be capable to implement your idea in Java independently after 30 hours of lectures. Furthermore, I wish you could learn other programming languages without suffering from starting over.

The topics delivered in the following weeks are as follows:

In my humble opinion, I am trying to show you a big picture about COMPUTER SCIENCE.

Prerequisites

Text

Overview

Procedural programming

Object-oriented programming

Utilities

Data structures and algorithms

Design patterns

Schedule [ 247, 250, 251, 252, 253, 254, 255, 260, 261, 263, 265, 266, 268, 269, 271, 274, 275, 276, 277, 278, 280, 281, 281n, 282, 283, 284, 286, 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, 301, 304, 305, 306, 307, 308, 310, 311, 312, 313, 314, 315, 318 ]

Date Summary
2019.7.6 (3h30m) programs, computational solutions, computer systems (CPU-memory model), programming languages, algorithms, JDK + Eclipse, first Java program, variables;
2019.7.7 (3h30m) data types (int, double, char, boolean) (see computer arithmetics), assignment operator (=), arithmetic operators (+, −, *, /, %), type conversion, casting, rational operators (>, <, ==), logical operators (!, &&, ||, ∧), compound arithmetic operators (+=, ++), reference types, Scanner object, stack & heap, selections (if-else if-else); HW0: Lab 0;
2019.7.13 (3h30m) selections (switch-case-default, ?: operator), while loops, do-while loops, for loops (also see pp. 8-10 of the slides 20180824.pdf for programming games), jump statements, nested loops;
2019.7.14 (3h30m) analysis of algorithms (also read analysis of algorithms for further details), arrays, for-each loops; HW1: Lab 1 and Lab 2 due 7.20;
2019.7.20 (3h30m) briefing data structures, sorting algorithms, searching algorithms, higher-dimensional arrays, methods, call stack, scope of variable, method overloading, recursion;
2019.7.21 (3h30m) class & object (also read what makes OOP ``good''?), fields and methods, encapsulation, constructors, this operator, static members, garbage collection, HAS-A relationship (aggregation) (also see memory and objects from Stanford University), IS-A relationships, inheritance, super operator, method overriding (worth to read these slides); HW2: Lab 3, Lab 4, and Lab 5 due 8.4;
2019.7.27 subtype polymorphism, up/down casting, instanceof operator, final variable/method/class, abstract class/method, interface, wrapper class, immutability, enum type, namespace, nested class, anonymous class, iterator, package;
2019.7.28 assertion and exception handling, Java graphics and GUIs, Java event handling (also read events, listeners, callbacks), Java 2D games tutorial (see snake game);
2019.8.3 no class due to power cut;
2019.8.4
Promotion Java Programming 2 (sign-up);

Sample code

Gradebook

Programming Labs

Grading Policy Since Java 310, I've canceled the final exam for your final grade. As the minimal requirement to acquire the certificate of course completion, you need to finish all labs w/o OPTIONAL. I suggest that you could try optional labs as many as possible. For the record, this course is offered without any course credit of National Taiwan University, in compliance with Implementation Regulations Governing Colleges Continuing Education, Ministry of Education.

Late Homework Policy All programming labs should be submitted before the last date of class in order to deliver your final grades to the office so that the certificates can be issued soon. (See a recent complaint letter here.)

Homework Submission Send the source code (the file with .java extension) to my email shown in the beginning of this page. Remember to indicate this class number, your full Chinese name, and homework number in your email title. For example, [Java318] Homework 1 盧政良. Do not attach any class file because any executable file will be ruled out by Gmail.

References

Java (introductory level)

Java (advanced level)

Data structures and algorithms

Object-oriented analysis and design

Computer organization/architecture

AP Computer Science related

Misc

Additional reading