SE1011
Outcomes
This is an old version of this course, from Fall 2014. A newer version is available here.
Optional Goodies
- IntelliJ
- How to set up the editor so it's more like Word or Notepad when you click on line-endings. Just use Ctl-Right, Ctl-Left. Or ask me how to change the configuration.
- How to set up the default template
- How to put line numbers: Menu: File-> Settings. Tree: Editor->Appearance. Checkbox: Show line numbers. (Thanks to Pat & Nate for showing me how to do this.)
Week 1
Primitive datatypes, Variables, Identifiers
- List the primitive types supported in Java:
int
,long
,float
,double
,char
, andboolean
- Java tutorial on primitive types and literals that is really quite good. (Optional)
- Define 'numeric literal' and provide an example of one.
- Define 'char literal' (or 'character literal') and provide an example of one.
- Select the most appropriate primitive type to store a given piece of data
- Define 'assignment statement'
- Use the assignment statement
- Describe what happens in memory when a primitive variable is declared
- Describe what happens in memory when an object identifier (reference) is declared
- Describe the differences between primitives and objects (reference variables)
- Define 'String literal' and provide an example of one
- Draw a memory diagram illustrating the difference between primitives (e.g. int) and reference (e.g. String) types.
- Demonstrate how an instance of a class is created (new operator)
- Determine whether an identifier (e.g. variable name or class name) is valid or not.
Java Programming Basics
- Recognize code documentation in source code
- Demonstrate at least two forms of syntax for adding comments to source code
- Use Ctl-left and Ctl-right to navigate code in IntelliJ (optional)
- Comment and un-comment by hand and using the Ctrl-/ keyboard shortcut (optional)
- Replace hard coded constants with named constants
Standard Java Classes
- Demonstrate the use of
String.substring
- Demonstrate the use of
String.length
- Demonstrate the use of
String.charAt
- Use Oracle's Java documentation to ascertain if a method is part of a given class
Arithmetic expressions
- Demonstrate proper use of the following arithmetic operators:
+
,-
,*
,/
,%
- Identify and avoid unintended integer division errors
- Distinguish between binary and unary operations
- Define operator precedence
- Interpret arithmetic expresions following operator precedence rules (Second Edition of Text, Fig. 3.7, p. 84)
- Define and apply typecasting
- Interpret code that makes use of compound assignment operations:
*=
,/=
,+=
, -=, and%=
Week 2
Standard input/output
- Use wrapper classes to perform type conversion, e.g.,
int num = Integer.parseInt("14");
- Explain the source of data associated with the system input buffer:
System.in
- Perform standard/console input using the
Scanner
class - Explain the destination for data sent to the system output buffer:
System.out
- Perform standard/console output using the
System.out.println
method - Demonstrate the use of
JOptionPane.showMessageDialog
- Demonstrate the use of
JOptionPane.showInputDialog
Writing Computer Software
- Describe the steps involved in creating and running a Java program
- Describe the contents of source (
.java
) and class (.class
) files - Explain what happens (at a high level) when a Java program is compiled
- Explain what happens (at a high level) when a Java program is run
- Describe the difference between compilation and execution errors
- Explain why a Java Virtual Machine (JVM) is required in order to run a Java program
- Describe how bytecode makes Java programs portable
- List the basic steps involved in software development
Algorithms and Design
- Define the term algorithm
- Explain the motivation for doing design before coding
- Make use of variables and operations to perform calculations
- Construct and interpret flowcharts representing sequential, conditional, and looping structures
- Construct and interpret pseudocode representing sequential, conditional, and looping structures
- Use flowcharts and pseudocode to describe algorithmic solutions to simple problems
- Trace a program to debug it without running it
- Describe why ← is used instead of "=" in pseudocode, and why it points left instead of right.
- Describe the key differences between low-level and high-level pseudocode, and be able to write low-level pseudocode for simple problems
- Indentation of selection statements & loops
Week 3
Selection statements
- Define the functionality of the following relational operators:
<
,<=
,!=
,==
,>=
,>
- Apply De-Morgan's Theorem to simplify negated boolean expressions
- Simplify redundant boolean expressions such as
x || true
andx || !x
- Use relational operators to control program flow
- Define the functionality of the following boolean operators:
&&
,||
, and!
- Use boolean and relational operators to construct meaningful boolean expressions
- Use boolean expressions to control program flow
- Describe the behavior of an
if
statement - Describe the program flow through a series of nested
if
statements - Use nested
if
statements to control program flow - Convert messy flow diagrams to clean loop structures 0
- Correctly indent & interpret nested if, while, for, etc. statements
- Use tab, Shift-tab and Ctr-shift-tab to indent code
- Use ctrl-a, ctrl-alt-i to automatically correct indentation in code (after this quarter, use sparingly!) (optional)
- Rewrite a
switch
statement with one or more (potentially nested)if
statements - Explain the purpose of the
case
,break
anddefault
reserved words - Use boolean variables to save the results of comparisons and other true-false values when it helps clarify code.
- Define "scope" and describe why scope is important in understanding certain errors associated with if-blocks
- Correct errors associated with scope & if-blocks
- Explain why there is no semi-colon after the if header
Iteration statements
- Use a
switch
statement to control program flow - Dr. Hasker's 5 steps for writing a while loop. (Optional)
- identify exit condition: what must be true when exit loop
- write opposite form of step 1 as the condition of the while loop
- write pseudocode for loop body
- Add setup: initialization/read data
- Add cleanup: restore data, close files
- Describe the differences between counting, use-input, and sentinal-value loops.
- Select the most appropriate type of loop for a given problem and implement it from scratch.
- Interpret code that makes use of the following looping constructs:
while
,do-while
, andfor
- Design and write code that makes use of the following looping constructs:
while
,do-while
, andfor
- Describe how the following constructs differ:
while
,do-while
, andfor
- Rewrite a given
while
loop into an equivalentfor
loop, and vice versa - Use System.out for debugging loops
Needed?
Week 4
More Standard Java Classes
- Define an Application Programming Interface (API)
- Use Oracle's Java documentation to ascertain the capabilities of a given standard java class
- Use the Javadoc page for the
Math
class to perform calculations involving the following mathematic operations:- Absolute value
- Trigonometric functions (in degrees and radians)
- pi - ratio of the circumference of a circle to its diameter
- xy
- logarithmic functions
- maximum/minimum of two numbers
- Square root
- Use parsing methods in wrapper classes to convert text representations of numbers into numeric format
- Use the
toString
method in wrapper classes to convert from numeric format into text representations - Be familiar with methods from the
Character
class such asisDigit
andtoLowercase
- Use methods from the
String
class such asisEmpty
,substring
,indexOf
, etc... - Generate random numbers
- Use
System.out.printf
to produce formatted output
Week 5
Java Packages
- Explain the purpose of a Java package
- List at least two packages that are part of the Java standard library
- Define the term fully qualified name
- Explain the purpose of the
import
statement
Coding Standards
- Explain the purpose of a coding standard
- Be familiar with Oracle's coding conventions.
Week 6
Object Oriented Design / Object Oriented Programming
- Define the following object oriented concepts:
- Object types (Classes)
- Class instances (Objects)
- Instance variables (Attributes/Fields)
- Instance behaviors/actions (Methods)
- Distinguish between classes and objects
- Describe how objects interact with one another by sending messages
UML
- Correctly annotate and interpret fields (name and type) on a class diagram
- Correctly annotate and interpret methods (with arguments and return type) on a class diagram
- Generating class diagram from a verbal description of a class
- Interpret UML sequence diagrams
- Use visibility modifiers to denote the visibility of a field or method
Class creation basics
- Define "object" and describe how it is different from a primitive type
- Explain the advantage of objects having methods associated with them
- Explain the differences between a class & a primitive type: e.g. use references, multiple variables lumped together, methods associated with them
- Define "instance" and describe what it means in memory
- Define and use classes with multiple methods and data members (fields)
- Define and use value-returning and void methods
- Properly use visibility modifiers in defining methods and fields
- Define and use class constants
- Understand and apply accessor and mutator methods
- Distinguish between instance variables and local variables
- Define and use instance methods and instance variables (attributes/fields)
- Define and use methods that have primitive data types as arguments
- Define encapsulation and give an example where it is important
- Understand the importance of information hiding and encapsulation
- Declare and use local variables
- Describe the role of the reserved word
this
- Demonstrate use of
this
to disambiguate object fields from local variables - Use System.out for debugging all classes, not just the driver.
Week 7
Defining your own classes
- Create and use class constructors
- Define and use methods that have reference data types as arguments
- Define and use overloaded methods
- Call methods of the same class
- Draw and explain memory diagrams that illustrate the instantiation of objects
- Describe the role of the garbage collector
- Compare the equality of two different objects
- Swap the data in two different objects
- Avoid redundant code by calling one constructor from a different constructor
- Understand the implications of acting on an object to which there are multiple references
- Watch this Fun video on references (pointers) from Stanford. (Optional.)
- Trace a program including calls to class methods in multiple classes.
- Use the debugger to watch the computer "trace" the class.
Week 8
Design Techniques
- Use helper methods to avoid redundant code
- Adhere to the MSOE Software Development Laboratory coding standard
- Simplify complicated algorithms by encapsulating subordinate tasks
- Be familiar with various design approaches such as top-down, bottom-up, and case-based
- Use mechanisms in Eclipse to refactor software
- Comment each method using the Javadoc convention
Week 9
Class Members
- Use class variables/attributes appropriately
- Use class methods appropriately
Arrays
- Use an array to store primitive and object types
- Create an array of a given size
- Loop through an array
- Pass an array as an argument
- Remember that "length" is a property, not a method of an array
Week 10
ArrayLists
- Use an ArrayList<E> to store objects type
E
- Use methods from the ArrayList<E> class such as
isEmpty
,get
,set
,add
,remove
,size
,indexOf
, andlastIndexOf
- Design and write code that makes use of the enhanced for loop, a.k.a, the for-each loop
- Describe the advantages of an ArrayList<E> over an Array
Last modified: Monday, 05-Aug-2013 15:09:18 CDT