Here's what we did to run the three programs from Chapter 2 on Windows from the prompt. 

Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.

C:\Users\dgerman>dir
 Volume in drive C is OSDisk
 Volume Serial Number is 1ECC-7CC7

 Directory of C:\Users\dgerman

06/27/2016  11:51 AM    <DIR>          .
06/27/2016  11:51 AM    <DIR>          ..
07/08/2014  11:43 AM    <DIR>          .datastudio
06/27/2016  11:51 AM    <DIR>          .oracle_jre_usage
06/27/2016  11:41 AM    <DIR>          Contacts
06/27/2016  11:45 AM    <DIR>          Desktop
06/27/2016  11:41 AM    <DIR>          Documents
06/27/2016  11:45 AM    <DIR>          Downloads
06/27/2016  11:41 AM    <DIR>          Favorites
06/27/2016  11:41 AM    <DIR>          Links
06/27/2016  11:41 AM    <DIR>          Music
06/27/2016  11:41 AM    <DIR>          Pictures
06/27/2016  11:41 AM    <DIR>          Saved Games
06/27/2016  11:42 AM    <DIR>          Searches
06/27/2016  11:41 AM    <DIR>          Videos
               0 File(s)              0 bytes
              15 Dir(s)  114,344,964,096 bytes free

C:\Users\dgerman>cd Desktop

C:\Users\dgerman\Desktop>dir
 Volume in drive C is OSDisk
 Volume Serial Number is 1ECC-7CC7

 Directory of C:\Users\dgerman\Desktop

06/27/2016  11:45 AM    <DIR>          .
06/27/2016  11:45 AM    <DIR>          ..
06/27/2016  11:45 AM        40,449,114 textbook.pdf
               1 File(s)     40,449,114 bytes
               2 Dir(s)  114,344,964,096 bytes free

C:\Users\dgerman\Desktop>dir
 Volume in drive C is OSDisk
 Volume Serial Number is 1ECC-7CC7

 Directory of C:\Users\dgerman\Desktop

06/27/2016  12:02 PM    <DIR>          .
06/27/2016  12:02 PM    <DIR>          ..
06/27/2016  11:45 AM        40,449,114 textbook.pdf
06/27/2016  12:02 PM               399 Welcome.java
               2 File(s)     40,449,513 bytes
               2 Dir(s)  114,344,751,104 bytes free

C:\Users\dgerman\Desktop>javac Welcome.java
'javac' is not recognized as an internal or external command, operable program or batch file.

C:\Users\dgerman\Desktop>"C:\Program Files\Java\jdk1.8.0_51\bin\javac.exe" Welcome.java

C:\Users\dgerman\Desktop>"C:\Program Files\Java\jdk1.8.0_51\bin\java.exe" Welcome
Welcome to Core Java!
=====================

C:\Users\dgerman\Desktop>PATH=%PATH%;"C:\Program Files\Java\jdk1.8.0_51\bin"

C:\Users\dgerman\Desktop>javac
Usage: javac <options> <source files>
where possible options include:
  -g                         Generate all debugging info
  -g:none                    Generate no debugging info
  -g:{lines,vars,source}     Generate only some debugging info
  -nowarn                    Generate no warnings
  -verbose                   Output messages about what the compiler is doing
  -deprecation               Output source locations where deprecated APIs are used
  -classpath <path>          Specify where to find user class files and annotation processors
  -cp <path>                 Specify where to find user class files and annotation processors
  -sourcepath <path>         Specify where to find input source files
  -bootclasspath <path>      Override location of bootstrap class files
  -extdirs <dirs>            Override location of installed extensions
  -endorseddirs <dirs>       Override location of endorsed standards path
  -proc:{none,only}          Control whether annotation processing and/or compilation is done.
  -processor <class1>[,<class2>,<class3>...] Names of the annotation processors to run; bypasses default discovery process
  -processorpath <path>      Specify where to find annotation processors
  -parameters                Generate metadata for reflection on method parameters
  -d <directory>             Specify where to place generated class files
  -s <directory>             Specify where to place generated source files
  -h <directory>             Specify where to place generated native header files
  -implicit:{none,class}     Specify whether or not to generate class files for implicitly referenced files
  -encoding <encoding>       Specify character encoding used by source files
  -source <release>          Provide source compatibility with specified release

  -target <release>          Generate class files for specific VM version
  -profile <profile>         Check that API used is available in the specified profile
  -version                   Version information
  -help                      Print a synopsis of standard options
  -Akey[=value]              Options to pass to annotation processors
  -X                         Print a synopsis of nonstandard options
  -J<flag>                   Pass <flag> directly to the runtime system
  -Werror                    Terminate compilation if warnings occur
  @<filename>                Read options and filenames from file


C:\Users\dgerman\Desktop>javac ImageViewerFrame.java
ImageViewerFrame.java:10: error: class ImageViewer is public, should be declared in a file named ImageViewer.java

public class ImageViewer
       ^
1 error

C:\Users\dgerman\Desktop>javac ImageViewer.java

C:\Users\dgerman\Desktop>java ImageViewer

C:\Users\dgerman\Desktop>java ImageViewer

C:\Users\dgerman\Desktop>dir Road*
 Volume in drive C is OSDisk
 Volume Serial Number is 1ECC-7CC7

 Directory of C:\Users\dgerman\Desktop

06/27/2016  12:21 PM             1,279 RoadApplet.java
06/27/2016  12:20 PM             3,155 RoadComponent.java
               2 File(s)          4,434 bytes
               0 Dir(s)  114,336,829,440 bytes free

C:\Users\dgerman\Desktop>javac Road*.java

C:\Users\dgerman\Desktop>dir Road*
 Volume in drive C is OSDisk
 Volume Serial Number is 1ECC-7CC7

 Directory of C:\Users\dgerman\Desktop

06/27/2016  12:22 PM             1,439 Road.class
06/27/2016  12:22 PM             2,131 RoadApplet.class
06/27/2016  12:21 PM             1,279 RoadApplet.java
06/27/2016  12:22 PM             1,508 RoadComponent.class
06/27/2016  12:20 PM             3,155 RoadComponent.java
               5 File(s)          9,512 bytes
               0 Dir(s)  114,336,776,192 bytes free

C:\Users\dgerman\Desktop>dir *.html
 Volume in drive C is OSDisk
 Volume Serial Number is 1ECC-7CC7

 Directory of C:\Users\dgerman\Desktop

06/27/2016  12:24 PM             3,396 RoadApplet.html
               1 File(s)          3,396 bytes
               0 Dir(s)  114,336,698,368 bytes free

C:\Users\dgerman\Desktop>appletviewer RoadApplet.html
Warning: Can't read AppletViewer properties file: C:\Users\dgerman\.hotjava\properties Using defaults.

C:\Users\dgerman\Desktop>

Here now are the code for the three programs:

(a) 

http://www.cs.indiana.edu/classes/c212-dgerman/sum2016/abracadabra/corejava/v1ch02/Welcome/Welcome.java

(b)

http://www.cs.indiana.edu/classes/c212-dgerman/sum2016/abracadabra/corejava/v1ch02/ImageViewer/ImageViewer.java

We used this picture with the viewer:

http://www.artpetrus.com/swf/subpage/page12/slider3.jpg

Save it on the desktop, then load it from the File menu.

The online repository has other pictures like

http://www.cs.indiana.edu/classes/c212-dgerman/sum2016/abracadabra/corejava/v1ch02/ImageViewer/mug.png

(c) 

http://www.cs.indiana.edu/classes/c212-dgerman/sum2016/abracadabra/corejava/v1ch02/RoadApplet/RoadComponent.java

http://www.cs.indiana.edu/classes/c212-dgerman/sum2016/abracadabra/corejava/v1ch02/RoadApplet/RoadApplet.java

http://www.cs.indiana.edu/classes/c212-dgerman/sum2016/abracadabra/corejava/v1ch02/RoadApplet/RoadApplet.html

We also discussed at length how we can use appletviewer and the benefits of Firefox. 

--