The ‘SS James Longstreet after long use as a target ship’ in Cape Cod Bay off Eastham MA. from http://www.armed-guard.com/calen3.html, the Liberty Ship site.
Tuesday, August 07, 2001
The ‘SS James Longstreet after long use as a target ship’ in Cape Cod Bay off Eastham MA. from http://www.armed-guard.com/calen3.html, the Liberty Ship site.
Among Robert Louis Stevenson's earliest childhood memories was his first train journey from Waverley Station in Edinburgh to North Berwick for the family holiday. His grandfather's house at Anchor Villa was idea for exploring the beaches and coves, climbing rocks, fishing and campfires at the Leithies and Seacliff with his nanny 'Cummie'. It was at Scoughall Farm on the mainland opposite the Bass that Stevenson spent several boyhood holidays as the land belonged to his relatives, the Dale family. It was here in front of the farmhouse fire that the young Stevenson first heard the story of how the 'Pagans of Scoughall' on wild stormy nights, lured sailing ships onto the rocky reef called the Great Car by displaying misleading lantern lights. This gave Stevenson the idea for his story called 'The Wreckers'.
The novelist's grandfather, Robert Stevenson was appointed Engineer to the Lighthouse Commissioners in 1808 and the Civil Engineering company he founded, designed and constructed the lighthouse on the Bass (1902) and Fidra (1885). The Bass Rock Lighthouse was manned by three keepers until 1988 when it was automated. Today the Bass remains in the ownership of Sir Hew Hamilton-Dalrymple.’
Monday, July 09, 2001
The following hoax pages are good to check out when you get an inflammatory piece of 'net detritus: | |
http://www.kumite.com/myths/ | Rob Rosenberger's Computer Virus Myths |
http://ciac.llnl.gov/ciac/CIACHoaxes.html | DoE Computer Incident Advisory Capability internet hoaxes |
http://urbanlegends.about.com/ | About.com Urban Legends & Folklore (lists many of the other sites) |
http://206.129.0.238/~larry/rumorcontrol/ | Larry Gilbert's Rumor Control page |
http://www.snopes.com/ | Urban Legends Reference Page |
http://www.lycos.com/wguide/wire/wire_484526_88215_3_1.html | Lycos Urban Legends |
http://ciac.llnl.gov/ciac/CIACChainLetters.html | DoE Computer Incident Advisory Capability internet chain-letters |
http://chainletters.org/ | Internet chain-letters |
http://www.cert.org/ | CERT Coordination Center - tracks real internet security breaches |
Tuesday, July 03, 2001
Wednesday, June 06, 2001
Monday, June 04, 2001
Friday, May 25, 2001
Thursday, May 24, 2001
http://www.activism.net/cypherpunk/
http://www.csua.berkeley.edu/cypherpunks/Home.html
Sun Java resources:
Java 2 (JDK 1.2) home: http://www.javasoft.com/products/jdk/1.2/
Download the Lose32 version of JDK 1.2.2: http://www.javasoft.com/products/jdk/1.2/download-windows.html
Java 1.2 (on-line) documentation: http://www.javasoft.com/products/jdk/1.2/docs/
Java 1.2 on-line package documentation: http://www.javasoft.com/products/jdk/1.2/docs/api/overview-summary.html
Java Tutorial: http://java.sun.com/docs/books/tutorial/
Non-Sun on-line resources:
Marty Hall's Java Programming Resources: http://www.apl.jhu.edu/~hall/java/
Java Lobby: http://www.javalobby.org/
Robert Hurd's CodeCollection Java source: http://www.codecollection.com/java/source/
The Giant Java Tree source code: http://www.gjt.org/pkgdoc/tree/
Cliff Berg's DDJ Java source code: http://www.digitalfocus.com/ddj/code/
Java in a Nutshell Examples source code: http://www.oreilly.com/catalog/jenut/examples/
FreeCode Java: http://www.freecode.com/cgi-bin/search.pl?query=java
EarthWeb Java: http://www.developer.com/downloads/freeware/java.html
Peter Ellehauge's Java resources: http://www.triathlon.dk/triguy/java/
Cygnus Java compiler (FYI): http://sourceware.cygnus.com/java/
Java Books:
Start with _Java in a Nutshell_: http://www.ora.com/catalog/javanut3/
Emacs resources (especially for Java):
The JDE page: http://sunsite.auc.dk/jde/
The Lose32 Emacs download page: http://www.cs.washington.edu/homes/voelker/ntemacs.html
The Gnu Emacs page: http://www.gnu.org/software/emacs/
Python resources:
Everything: http://www.python.org/
If you have any questions, just ask!
======================================================================
> Example, gcd (2520, 154)
>
> 2520 = 154 (16) + 56
> 154 = 56(2) + 42
> 56 = 42(1) + 14
> 42 = 14(3) + 0
Oh those clever Greeks...
I attach our recent hacks _plus_ a GCD implementation. The Gcd class probably ought to have a static method for gcd( n1, n2 ) & _no_ instance variables (fields). This version kinda has both. What do you think?
%MY_JAVA%\java.bat:
: Set up these environment variables appropriate to your file system
SET MY_JAVA=c:\temp\java
SET JAVA_HOME=c:\work\jdk1.2.2
SET CLASSPATH=%JAVA_HOME%\jre\lib\rt.jar;%MY_JAVA%
: Move to the source code directory (%MY_JAVA%\test)
CD %MY_JAVA%\test
: Compile source code
%JAVA_HOME%\bin\javac Test.java Gcd.java
: Run resulting classes
%JAVA_HOME%\bin\java test.Test -s 123456
%JAVA_HOME%\bin\java test.Gcd 2520 154
%MY_JAVA%\test\Test.java:
//////////////////////////////////////////////////////////////////////
//
// test.Test
//
//////////////////////////////////////////////////////////////////////
package test;
public class Test {
Test( int seed ) {
java.util.Random rand = new java.util.Random( seed );
for ( int i = 1; i < 10; ++i ) {
System.out.println( rand.nextInt( ) );
}
}
static void usage( ) {
System.out.println( "usage: java test.Test -s SEED" );
System.exit( -1 );
}
public static void main ( String[ ] args ) {
int seed = 12345;
// Parse the command line argument.
try {
for ( int i = 0; i < args.length; ++i ) {
if ( args[ i ].startsWith( "-" ) ) {
// Process command-line switch arguments.
if( args[ i ].startsWith( "-s" ) ) {
seed = Integer.parseInt( args[ ++i ] );
continue;
}
}
// Invalid command-line switch.
usage( );
}
}
catch ( NumberFormatException e ) {
usage( );
}
Test test = new Test( seed );
}
}
%MY_JAVA%\test\Gcd.java:
//////////////////////////////////////////////////////////////////////
//
// test.Gcd
//
//////////////////////////////////////////////////////////////////////
package test;
public class Gcd {
// Fields
int n1; // first integer
int n2; // second integer
// Constructors.
Gcd( int n1, int n2 ) {
this.n1 = java.lang.Math.max( n1, n2 ); // initialize first integer
this.n2 = java.lang.Math.min( n1, n2 ); // initialize second integer
}
// Methods.
public int gcd( ) {
return ( gcd( n1, n2 ) );
}
public int gcd( int n1, int n2 ) {
int modulus = n1 % n2; // saves one division if n1 > n2
if ( modulus == 0 ) {
return ( n2 );
}
else {
return ( gcd( n2, modulus ) );
}
}
static void usage( ) {
System.out.println( "usage: java test.Gcd INT1 INT2" );
System.exit( -1 );
}
public static void main ( String[ ] args ) {
int n1 = 2520;
int n2 = 154;
// Parse the command line argument.
try {
for ( int i = 0; i < args.length; ++i ) {
if ( args[ i ].startsWith( "-" ) ) {
// Process command-line switch arguments.
}
else {
// Process two command-line numerical arguments.
n1 = Integer.parseInt( args[ i++ ] );
n2 = Integer.parseInt( args[ i++ ] );
continue;
}
// Invalid command-line switch.
usage( );
}
}
catch ( java.lang.ArrayIndexOutOfBoundsException e ) {
usage( );
}
catch ( java.lang.NumberFormatException e ) {
usage( );
}
Gcd gcd = new Gcd( n1, n2 );
System.out.println( "test.Gcd: " +
"GCD( " + n1 + ", " + n2 + " ) = " + gcd.gcd( ) );
}
}
When I ran JAVA.BAT (after installing jdk1.2.2 in %JAVA_HOME% & these *.java files in %MY_JAVA%) I got the following output:
C:\temp\java\test>..\java.bat
C:\temp\java\test>SET MY_JAVA=c:\temp\java
C:\temp\java\test>SET JAVA_HOME=c:\work\jdk1.2.2
C:\temp\java\test>SET CLASSPATH=c:\work\jdk1.2.2\jre\lib\rt.jar;c:\temp\java
C:\temp\java\test>CD c:\temp\java\test
C:\temp\java\test>c:\work\jdk1.2.2\bin\javac Test.java Gcd.java
C:\temp\java\test>c:\work\jdk1.2.2\bin\java test.Test -s 123456
1774763047
-506496402
-41169962
2018695370
1083428877
298499967
-1264165101
1316144193
315415608
C:\temp\java\test>c:\work\jdk1.2.2\bin\java test.Gcd 2520 154
test.Gcd: GCD( 2520, 154 ) = 14
Have fun!
- dcp
p.s. Once you have the GCD then:
// LCM is the least common multiple of n1 & n2
public int lcm( int n1, int n2 ) {
return ( n1 * n2 / gcd( n1, n2 ) );
}
piece of 'net detritus:
HOAXES, MYTHS, URBAN LEGENDS, & OVERBLOWN THREATS
http://www.kumite.com/myths/ Rob Rosenberger's Computer Virus Myths
http://ciac.llnl.gov/ciac/CIACHoaxes.html DoE Computer Incident Advisory
Capability internet hoaxes
http://urbanlegends.about.com/ About.com Urban Legends & Folklore
(lists many of the other sites)
http://206.129.0.238/~larry/rumorcontrol/ Larry Gilbert's Rumor Control page
URBAN LEGENDS
http://www.snopes.com/ Urban Legends Reference Page
http://www.lycos.com/wguide/wire/wire_484526_88215_3_1.html Lycos Urban Legends
CHAIN LETTERS
http://ciac.llnl.gov/ciac/CIACChainLetters.html DoE Computer Incident Advisory
Capability internet chain-letters
http://chainletters.org/ Internet chain-letters
SECURITY
http://cve.mitre.org/ Mitre's common vulnerabilities and exposures (CVE) list
http://www.cert.org/ CERT Coordination Center - tracks real internet security breaches
http://www.cerias.purdue.edu/ Purdue Center for Education and Research in Information Assurance and Security
http://xforce.iss.net/ Internet Security Systems XForce database
http://www.ntbugtraq.com/ Russ Cooper's NT Bug database
http://www.securityfocus.com/bid/ Security Focus vulnerability database
COMMERCIAL ANTI-VIRUS
http://vil.nai.com/villib/alpha.asp Network Associates' Virus Library
http://www.symantec.com/avcenter/ Symantec AntiVirus Research Center
CHARLES LAQUIDARA'S BIG MATTRESS - INTERNET SAVY 1007
http://www.bigmattress.com/internet%20savvy.htm
M$ VIRUSWARE
Neeed M$ Word macro virus references...
http://www.ntbugtraq.com/default.asp?sid=1&pid=47&aid=56 Outlook FAQ
http://vil.nai.com/vil/vm10132.asp Melissa
http://vil.nai.com/vil/vbs10418.asp Bubbleboy
Wednesday, May 23, 2001
Thursday, May 17, 2001
Wednesday, May 16, 2001
Monday, May 14, 2001
Tired of waiting for that clever e-mail? Just go to CoolSigs.com.
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GE d- s: a+ C++$ UL+ P--- L+>+++ E W++ N+ !o !K w !O M+ V PS++ PE Y+>++ PGP>+++ !t 5? X? R* tv--- b++ DI++ !D G e++ h---- r+++ y++++**
------END GEEK CODE BLOCK------
My GEEK CODE BLOCK decoded.