J
Jussi Jumppanen
An example of why Java is a stupid overly complicated
programming language:
import java.io.*;
public class SimpleJavaQuestion
{
public static void main(String[] args)
{
try
{
String line = "";
// surely the first character of the line is not a '#' character
if (line.charAt(0) != '#')
{
System.out.println("Never expect the obvious....");
}
}
catch (Exception e)
{
// stupid me. there is no first character, how obvious!!!!!
System.out.println("When the unexpected is far more interesting.");
}
}
}
programming language:
import java.io.*;
public class SimpleJavaQuestion
{
public static void main(String[] args)
{
try
{
String line = "";
// surely the first character of the line is not a '#' character
if (line.charAt(0) != '#')
{
System.out.println("Never expect the obvious....");
}
}
catch (Exception e)
{
// stupid me. there is no first character, how obvious!!!!!
System.out.println("When the unexpected is far more interesting.");
}
}
}