Women in Technology

Hear us Roar



Article:
  Rethinking the Java Curriculum: Goodbye, HelloWorld!
Subject:   First use a template
Date:   2002-08-30 04:44:29
From:   mikkale
Having just finished teaching an introductory course on java, i get the impression that for teaching java as a first programming language, you first have to simplify a great deal in order to prevent students with little or no programming experience from being totally confused with different concepts that are not essential for the problem you are trying to solve, e.g. main being a static method and the consequences of that (compilation errors when referencing non-static members) required a quite big amount of time.


So now I use two different Class-templates for introduction:


1.
class MyClass {

public static void main(String[] args) {
MyClass m = new MyClass();
m.runApplication();
}


void runApplication() {
// insert your code here
}


}



2. if I need command line arguments, I use:


class MyClass {

public static void main(String[] args) {
MyClass m = new MyClass();
m.runApplication(args);
}


void runApplication(String[] commandLineArgs) {
// insert your code here
}


}


With these templates I only have to explain what runApplication does and thus don't have to explain access modifiers, static methods etc.


In future I'm thinking of using BlueJ because of its visualization of objects. I think that with BlueJ students should be able to get an understanding of OOP quicker. Especially I like the live introspection features of BlueJ. (But I think I first have to patch the Moe Editor because tab handling when using backspace is awful: Caret should snap back to previous tab if you delete whitespace at start of your line).

Main Topics Oldest First

Showing messages 1 through 1 of 1.

  • First use a template
    2005-06-07 23:53:18  sabra [View]