enum Pet {
DOG, CAT, PIG, RAT, FISH, COW, CHICKEN
}
enum Meat {
DOG, CAT, PIG, RAT, FISH, COW, CHICKEN
}
class animals {
public static void main(String[] args) { It's hard to concentrate when you're tired and cranky, so I wasted some time writing a simple calculator in several different languages.
A story about Google losing a patent lawsuit against Bedrock, an East Texas "patent troll" has been making the media rounds, but I haven't yet seen an analysis of the patent. All I see is talk about Linux being at risk. If Linux is at risk, so is Windows, and so are the Apple OSs, because there's very little novel about the patent.
So, the tokenizer's done, and the parser's code is written but not tested. The standard testing system included with NetBeans is JUnit.
I'm relearning Java, and strict typing now seems so important.
This is weird. The authors turn OpenOffice.org into a spreadsheet server -- and then create a front end in Dojo with Javascript, and tunnel events from the front end to the OOo spreadsheet via a Tomcat servlet.
I feel lame when it comes to mobile phone hacking because I'm so far behind the state of the art, by at least five or more years.
The Glassfish server includes a Ruby and Rails implementation.
There's a Java Python that's well established.
So, I'm studying J2ME, and for some reason (maybe the wrong version of CLDC?) I can't use random.getNext(n). I can't specify the range of the random number. What a pain.
I wanted to avoid doing floating point math, and fell back on a C trick. To get a random number from 0 to 500:
This is a repository of "novice" articles, written with the intent of driving more traffic to the site, and getting more ad clicks. It's pretty crass, I know, but the information may be very useful.
If you wish to comment, post this article on reddit or hacker news.