Quiz Page java The java quiz has changed! We have replaced java questions with answers! And from those answers you'll find further links to even more information - forums where you can ask questions, training courses, longer articles, and more. [link to quiz index] ...
If you really want the old quiz
questions, you can find them
here,
here,
here and
here ... and
with onward links to the possible answers to each question too.
Java - GenericsIf you're writing a Java program and you want to hold a whole series of objects of a similar type in a single variable, you can use and array ... except that you need to know HOW MANY of them there ...
javax.servlet cannot be resolved - how to solveTwo common problems in compiling Servlets for use within a Tomcat container ...
PROBLEM: My Java Compile of a Servlet says "javax.servlet cannot be resolved"
For example:
...
Java CLASSPATH explainedWhen you run a Java program (be it though the java virtual machine or as a servlet within a web or application container such as Tomcat), it's only the main code (class) that's initially loaded. Any ...
Long, Longer, Longest in JavaIf you want to find out how long a Film3 is, in the class that I use on our private Java Programming courses, you can call the getminutes method. That's standard OO stuff. But what if you want to ...
Pascals Triangle in Python and JavaThere are certain "party pieces" that I have during courses ... and on my Java Courses, a program to generate Pascal's Triangle in an array of arrays is one of them.
One of my delegates on today's ...
Javascript/HTML example, dynamic server monitorThere are times I want to keep an eye on our servers, but I don't really want to redraw my whole browser window (or even a frame!) to do it. So I've written a Javascript application to run in my ...
More HowTo diagrams - MySQL, Tomcat and JavaHere are some more diagrams "off the wall" from last week - showing "howto" and "whatis" information for Tomcat, Java and MySQL
Some Tomcat and Java Fundamentals
On the right of the board ... the ...
Diagrams to show you how - Tomcat, Java, PHPI like to work with a flipchart occasionally, and I have been doing so quite a bit this week, which is a week that I'm giving a wide ranging web server deployment course under Linux, covering both ...
Increasing Java Virtual Machine memory for TomcatQ. "How do I increase the memory that my Java Virtual Machine in Tomcat can use?" A question asked - not for the first time - by a delegate on todays's Deploying Apache httpd and Tomcat course.
A. ...
Linux and Java Course in LondonThere are certain locations which used to fill me with horror as to how I was going to work out the logistics of getting my equipment in and out for a course. And today's was one of those for which I ...
Ruby, C, Java and more - getting out of loopsbreak and continue statements have been available for loop control for many years, and others functionallity has been added such as Perl's redo. From today's Ruby Course, here's a table that ...
Java Compiler - needs all classes, compiles them all tooRemember that when you compile a java source file ...
a) You must have the classes it will use when it runs available to the compiler so that it can check (a bit frustrating at times if you're ...
Trying out our Java examples on our web siteWe've included all of the source code of our training examples on this web site for quite a long time now ... and about a year ago we put working copies of most of the PHP scripts up there too (we ...
Java - a demonstration of inheritance on just one pageHere's a challenge, just given to me by my Java Delegates, to put my complete example of a Rectangle and a a Circle class, both inheriting from a Shape base class, and a test harness ... on on a ...
Java (JSP and Servlet examples) live on our serverOn our Java Programming for the Web and Deploying Apache httpd and Tomcat courses, we provide a ready-written demonstration that includes simple web pages, a basic JSP, JSPs with tag libraries, and a ...
Learning Object Oriented Principles (and perhaps Java)During an intensive 3 day Java course last week, I gave an introduction to the principles of Object Oriented Design, and a very short segment on design principles (there's a limit to how much can be ...
Teaching Object Oriented Java with Students and Ice Cream"I'm getting tired of students. Can we do something else". So said my delegates at Cardiff University today. So we did Ice Cream and other deserts!
Perhaps I had better explain. I'm running a Java ...
Java, sorting, ArrayList example, genericsA Java ArrayList holds an ordered sequence of items like an array, but there are differences:
1. An ArrayList has no fixed size but can be extended by adding elements later
2. An ArrayList can only ...
Java - using super to call a method in the parent classIf you're writing a Java class in which you override a method from the base class, can you still make use of that base class method in your new code? Yes, you can. You want the super call.
Here's ...
First Class Java. First step and moving forward.Java is an Object Oriented language that's great for medium size through large to huge systems. Which means that it's not usually the best approach for short applications ... of the size that one ...
Java is a dynamic language .... (and comparison)Many older programmers are used to setting up an array of a fixed size and saying "that's fixed" ... for the duration of the program, if not for all time until the application is recompiled.
...
Single login and single threaded models - Java and PHPOn Apache Tomcat courses, I find myself explaining "single login" models and on some Java courses I explain single threaded models. In both cases, there are times that newcomers to the technologies ...
Effective Java training - the bootcamp approachOur public Java courses:
Java Bootcamp- 4 days
Java Programming for the Web - 5 days
Deploying Java Apps under Linux / Unix - 5 days
Apache httpd and Tomcat Deployment - 2 days
Our courses are modular ...
Question on division (Java) - Also Perl, PHP, Python ...Q:
What's the difference between % and /?
A:
/ returns the result of a division
% returns the remainder when you do a division.
Divide 18 by 7 you get 2, with a remainder of 4 (i.e. 4 left over).
...
A Golf Club Decision - Perl to Java
There are times that Java is the right language for an application and Perl is the wrong one - to the extent that investment in a rewrite is correct. But they are pretty rare.
I was very ...
GUI design - Sketch it out first! (Java / Swing example)"A picture paints a thousand words" ... and so it is when you're planning a graphic user interface, and implementing it. Yesterday, I picked up an old example of a dialer written in Java - you can ...
Java - Client side applet applications as well as server sideJava started off as being a client side language - and our first (1996) course concentrated on Applets and the awt - Abstract Windowing Toolkit - to which Swing was added quite soon. But Applets took ...
2008 course schedule - Perl, Python, PHP, Linux, Java Deployment, Ruby and moreIt's nearly the August Bank Holiday ... and the time of year when our minds turn to scheduling courses for the next year.
For 2008, I am proud to present:
Every 8 to 12 weeks:
Public courses in ...
An example of Java Inheritance from scratchOne of the most important topics for newcomers to OO (Object oriented) programming to learn is how to design their classes and make best use of inheritance, and I find myself writing new examples from ...
An example of Java Inheritance from scratchOne of the most important topics for newcomers to OO (Object oriented) programming to learn is how to design their classes and make best use of inheritance, and I find myself writing new examples from ...
End of File on a Java BufferedReaderHow do you sense if a BufferedReader in Java has reached the end of file? Like so many "things Java" it's easy enough to do ... once you find that vital method in the lists of thousands of calls!
...
for loop - how it works (Perl, PHP, Java, C, etc)When writing a program, you'll often want to repeat a block of code, counting up through a table or performing a block of code with an input value (loop counter) that goes up 1, 2, 3, 4 etc.
You ...
Private Java Course - A customer's picturesIt's great to see customers coming on our courses and posting pictures up in public on places like Flickr ... especially when the pictures turn out to be better than mine.
Here are a some thumbnails ...
Java beans and classes, .war and .jar filesA Java Bean is a class that includes a constructor that takes no parameters, and getter and setter methods with names like getLength and setLength to read and write properties. So at a basic (Java) ...
Java Deployment course - lunch breakWe've several delegates on this week's course who are visiting the UK from overseas, and haven't been to Wiltshire before ... and the other delegates are staying with us. But the daylight is still ...
Serialization in Java - all layers required!If you want to subject a delicate piece of equipment to an extreme of temperture for a prolonged period, it's no good just putting it in a box, even if that box CAN withstand the temperature extreme. ...
Final, Finally and Finalize - three special words in JavaA final method or variable is one that can't be overridden - you can define a method as final within a class to ensure that any extensions to the class don't replace it.
If you add a finally block ...
Java sorting - comparable v comparatorIn Java, you can sort objects that implement the Collection interface, using either the comparable interface or a comparator class. What's the difference?
A Comparable interfaced class must contain ...
Java 6, Apache Tomcat 6.I greet new releases of software that we teach with a joy that the software is moving forward, but with an element of trepidation - "what's changed" I wonder. Although programming languages rarely ...
Java oversold?Oops ... I missed my blog entry yesterday - indeed, I had been up so early in the morning after a short night that I fell asleep around 8 p.m. and slept through - didn't even hear Lisa come in from ...
|
|