jwenting 1,905 duckman Team Colleague

that's a nice basic stack.
Turn your string into an array of char, feed those into the stack, then pop them while looping backwards through your char array.
If each pair match you have your palindrome, as soon as something doesn't match you know it's not a palindrome.

The shortest solution in Java I can come up with is

String str = "eye";
System.out.println(str + " is " + (!str.equals((new StringBuilder(str)).reverse().toString())?"not ":"" + " a palindrome");

but that obviously doesn't match your requirements (and try to explain it to your teacher ;) ).

jwenting 1,905 duckman Team Colleague

Strings are final. You can't change them once they're created, so you're going to have to create a new String based on the old one.

In your specific case you could use String newString = s.replace('b', 'B'); but keep in mind that that will replace ALL lowercase b's in the string with uppercase ones, and of course work only on lowercase b's.

A more generic solution would be something along the lines of String newString = s.substring(0,1).toUpperCase()+s.substring(1); but that will get rather slow if you call it a lot and can use up a lot of memory.

A better solution if you use it a lot would be to create a function that turns the string into a character array, update the first character of that (if it is within the range of lowercase letters), and return a new String generated from that character array.

jwenting 1,905 duckman Team Colleague

looks like you're missing a jarfile in your classpath. I don't have Oracle installed here so I can't tell you which one, but the name it gives as missing should be a good indication.

jwenting 1,905 duckman Team Colleague

Or better buy yourself a good modern Java teaching book like HeadFirst Java (2nd edition) or Agile Java.

jwenting 1,905 duckman Team Colleague

There are no headerfiles in Java.
I suggest you read up on import statements first of all...

And there is enough information there to know what a stack has in the form of operations.
From there you should be able to get a decent idea of what a stack actually does, which is the first step towards writing your own.

You might also want to get a decent book or two on data structures and algorithms.

jwenting 1,905 duckman Team Colleague

the compiler takes care of that for you. See the documentation on how to invoke it.

jwenting 1,905 duckman Team Colleague

you've obviously not read the API docs or you'd have found it.
There's a class called Stack which is well documented.

jwenting 1,905 duckman Team Colleague
string ponter = new string;

Now we have a ponter that is a string :)

jwenting 1,905 duckman Team Colleague

You should first learn to communicate in regular English, that should make it a lot easier to get your points across as well as making it a lot easier to find resources online and in your library.

When I put "cud" into a search engine I will find a lot of information about cows and camels for example, but I doubt that's what you had in mind.

If you do a little research in the API documentation (mandatory reading!) you'd find out where the Stack class and its brothers and sisters are located.

jwenting 1,905 duckman Team Colleague

break statements are no problem, it's labelled break statements that are asking for trouble.
And of course you should always know what you're doing (in one program I do use labelled breaks, because in that specific situation it's the cleanest solution I could come up with, everything else requiring a mess of nested if statements to prevent further execution under specific conditions).

jwenting 1,905 duckman Team Colleague

you're always going to need to know both the IP address AND the port AND the protocol to successfully talk with any server (and that is assuming you also are allowed to talk to it, know the usernames and passphrases needed, etc.).

jwenting 1,905 duckman Team Colleague

the codebase tag serves a similar purpose to the classpath environment setting in that it helps determine where the JVM should get classes for the applet.

jwenting 1,905 duckman Team Colleague

You're going to have to do something with the ListModel and maybe create a custom renderer as well.

jwenting 1,905 duckman Team Colleague

Those are warnings, not errors.

They're related to things that you're writing having been replaced by other methods and ways of working in the current language specification.
The first is because you're not using generics, causing typesafety on Collections to fail.
The second is you using an old method that is no longer advised for use. Check the API documentation for suggested alternatives.

jwenting 1,905 duckman Team Colleague

Console output is line based and non-exclusive.
Never assume you will have the entire screen or even an entire line at your disposal.

So you're not supposed to go back to a previous screen location and write there because it likely no longer contains what you originally wrote there (having scrolled away).

jwenting 1,905 duckman Team Colleague
int total = 0;
for (int i:elements) {
  total += i;
}
jwenting 1,905 duckman Team Colleague

well, you could write your own driver to access the mdb ;)

jwenting 1,905 duckman Team Colleague

That's not Java, that's Javascript, which is something completely different despite the similar name.

There's a separate forum for it.

jwenting 1,905 duckman Team Colleague

Check those loop conditions...
They're not checking for what you think they are.

jwenting 1,905 duckman Team Colleague

Modularity. That way you can use it in many places without having duplicate code.
It also keeps your classes small, which makes the code easier to read and maintain.

jwenting 1,905 duckman Team Colleague

the cost of keeping people on death row is indeed astronomical compared with the cost of just hanging them from the gallows at dusk.
Arrest at dawn, convict at noon, hang at dusk. No need for large expensive prisons.

Tree, rope, criminal. Some assembly required.

jwenting 1,905 duckman Team Colleague

simple enough indeed, easy mathematical sequence.
Program as a loop, several ways to determine whether to add or subtract.

Trickiest is how to determine when to terminate the loop, unless you're using a fixed number of iterations.

jwenting 1,905 duckman Team Colleague

That figure seems terribly low, unless prison staff work for free or prisons are extremely overcrowded and understaffed.

Maybe the direct cost (food, clothing, etc.) is $36K, the real cost is an order of magnitude higher.

jwenting 1,905 duckman Team Colleague

Because, as has been mentioned many times already, Math.cos (and Math.sin and others) are NOT going to convert degrees to radians for you.

Maybe you should learn about trigonometric calculations first before trying to use them in your software, maybe then things might become clear(er) to you.

jwenting 1,905 duckman Team Colleague

If they both provide access through JDBC the effort should be pretty similar.

Personally I think XML is WAY overused, mainly due to upper management in many companies dictating it be used everywhere without any knowledge of what it is or what it's good for.
While it might make sense sometimes to store XML in a database or to store data in XML format it makes no sense doing so for all data under all conditions.

jwenting 1,905 duckman Team Colleague

P.S. I've done a small test and Math.cos(x) yields correct results which are in line with the ones the Windows calculator produces down to their last decimal place (when the latter is set to radians of course).

The following will print the cosine of every angle between 0 and 2 pi:

double rad = 0.0;
            double interval = 0.1;
            
            while (rad < 2*Math.PI) {
                System.out.print(rad);
                System.out.print(" -> ");
                System.out.println(Math.cos(rad));
                rad += interval;
            }

Note that normally you'd format the output to make it look nicer...

jwenting 1,905 duckman Team Colleague

What are the values you are getting for 90 and 270? Shouldn't they both be 0 according to the unit circle?

yes, and when using radials they won't be 0 but roughly -.45 and +.98 respectively.

jwenting 1,905 duckman Team Colleague

no, the rest is wrong as well (though it is possible that by some chance a few distinct values might happen to be identical it's unlikely).
But they're less obviously wrong unless you know what to expect. Do you know the exact cosine of every angle to 10 decimal places without looking them up?

jwenting 1,905 duckman Team Colleague

Files are data... So you can send files if you know how to read and write them ;)

jwenting 1,905 duckman Team Colleague

yes, people can solve it in theory and practice.
In fact many people (including everyone who's ever made a batch based booking system) has already solved it.

All that means it's a problem that has a solution and as you want only a simple solution that solution should be easy to arrive at for someone smart enough to follow a course that asks you to create such a system.
As I assume at this point you're such a person and therefore by definition smart enough to do it yourself I wish you luck.
Were you not smart enough that would still be no reason to help you, in fact it would be reason to not help you as such would possibly prevent a person who's an imposter from getting some diploma they don't deserve.

jwenting 1,905 duckman Team Colleague

inside your JDBC driver.

jwenting 1,905 duckman Team Colleague

If you properly set up the application you can exit the application normally (with JVM shutdown) by using the operating system supplied features (like the close icon in the window corner) as well.

Something like

this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

in your main application frame should work wonders.

jwenting 1,905 duckman Team Colleague

no, I'm not going to help you asap. I MIGHT help you if you ask nicely in a year or so.

jwenting 1,905 duckman Team Colleague

update, installed the latest version of Vuescan and it works.

jwenting 1,905 duckman Team Colleague

I've installed PS Elements 4 (replacing PSP7 and PS Elements 1), but can't get it to work properly in combination with Vuescan.

When Vuescan is done scanning it starts PSE4 as required but the new file doesn't load.
When using the same setup (set the application to be used in the prefs tab) with either PSE1 or PSP7 everything works as intended.

Any ideas?

jwenting 1,905 duckman Team Colleague

except that it should be a String array of course ;)

jwenting 1,905 duckman Team Colleague

think about what you're doing there.
Each time the page is loaded you first get the data from the database and then write it back. That can't be what you're trying to do.

Then you're intending to write back what the user put into the webform, but you're never retrieving those parameters.
You're retrieving only one and that one doesn't even exist on the form so will always yield an empty string.

jwenting 1,905 duckman Team Colleague

Figure out some logical structure and stick with it, that's the general rule.
What that structure actually is is less important than sticking to it.

What I generally do is place classes together based on functionality.
So in your case I'd make a package for the user interface classes.
Under that subpackages for classes used only in the client and the server (with the shared classes in the base user interface package).
Make a parallel tree for utility classes, etc.

May seem a lot of work for a small application with one or two classes per package but when you get into larger projects with hundreds or thousands of classes it can really help.
Someone forgot to do that where I now work and we have more than a bit of duplicate functionality because classes are in places they shouldn't be and get forgotten about, packages have literally hundreds of classes that are only loosely related if at all, making them hard to find, etc.
It pays thinking about that package structure for a while before you start coding, a day or even a few days on a large project is no luxury.
That's part of the design process, book the time on someone else's budget ;)

jwenting 1,905 duckman Team Colleague

As said, as long as you use Java only (and not JNI for example) it's pure Java (though technically that term may possibly no longer be used since the software certification program was shut down a few years ago).

jwenting 1,905 duckman Team Colleague

Best call the responsible department directly. Seems they somehow managed to write something that doesn't work with modern JVMs (Java runtimes).

jwenting 1,905 duckman Team Colleague

Start with doing extensive research into the subject, and then determine whether it's feasible for your experience and deadline (if you have to ask whether something like this is even possible I'd guess to conclude in advance that it's not feasible for you).

jwenting 1,905 duckman Team Colleague

You don't, period.

jwenting 1,905 duckman Team Colleague

incorrect method signature for your main method usually.

jwenting 1,905 duckman Team Colleague

is that applepie or chocolate pie? :)

jwenting 1,905 duckman Team Colleague

Well, you can create great applications using VI.
If you insist on a GUI builder (or WYSIWYDG) Netbeans is the main free offering out there.

jwenting 1,905 duckman Team Colleague

different compared to what?

jwenting 1,905 duckman Team Colleague

The mathematics are well described in many publications. For the graphics there are several options, most notably OpenGL and Java2D.
Start with studying those separately, then combine that knowledge.

jwenting 1,905 duckman Team Colleague

well, your code doesn't add the combobox or the label to anything so it wouldn't be displayed.

jwenting 1,905 duckman Team Colleague

and of course several 3rd party ones, and you can make your own (if you have too much time on your hands or a very special need).

jwenting 1,905 duckman Team Colleague

headless: no videocard/monitor