jwenting 1,905 duckman Team Colleague

yes, you can add notes to an eBook. But try easily looking back through them in context...
Much easier to do with a dead tree than with a dead electron.

Reverend Jim commented: True dat. +0
jwenting 1,905 duckman Team Colleague
public class Grading {
  public static void main(String... args) {
    System.out.println("you fail!");
  }
}

That's pretty much the standard grade for the typical homework question...

In your case, right off the bat you fail to set "bigTemp" to the right number.
Stopped looking there.

jwenting 1,905 duckman Team Colleague

well, still waiting for that project idea generator. I'm sure you can make that networked...

jwenting 1,905 duckman Team Colleague

do you own homework, kiddo.

jwenting 1,905 duckman Team Colleague

Just ordered me 2 thick paper books. Study guides that are going to have a lot of dogears, sticky notes, yellow and green highlights, and penned in notes.

Can't do that as easily with an eBook, or browse back and forth between pages as quickly.

jwenting 1,905 duckman Team Colleague

and you're wrong. You have to use rmic to create the stub classes which then are compiled together with the rest of the code using javac.

jwenting 1,905 duckman Team Colleague

wonder what happened to the moderator who said he'd close this zombie 3 years ago. Did he die before hitting the close button?

jwenting 1,905 duckman Team Colleague

A company were to set that requirement for "security" I'd hand back the assignment and tell them I won't be responsible for the inevitable breach of security.

jwenting 1,905 duckman Team Colleague

nope, just stating facts.

I'm dead against forcing "gender neutral" anything. Let the children choose themselves, rather than force boys to be girls and girls to be boys for the sake of political correctness.
Which is the entire meaning of the "gender neutral" idiocy, examplified by the couple that forces their son to wear dresses for half the day because they consider him to be genderless...

jwenting 1,905 duckman Team Colleague

and the library has major flaws in that it's very hard to use, and has no way to rapidly (if at all) convert to and from the old Date logic.

It's simply Joda time bolted on to the core libraries, and just changing the package names and license statements in the sources took them years...
Used it in the past, it needs dozens of lines of code to simply convert a java.util.Date into a joda Date or back, and in any real application you need to do that all the time because you're interfacing with existing libraries, databases, etc. etc. etc.

IOW just another "me2" "feature" added for little other reason than to provide someone with the right to say he wrote a JSR.

For a while I was part of the team, they refused to even consider adding methods to convert to and from the existing API, not because it can't be done (it would have been easy), but because they "didn't want to pollute the API with code dealing with it", in other words for religious/political reasons.

And for some reason they explicitly added Muslim and Chinese calendar support, but not Jewish calendar support...
More political/religious bigotry at work where none should exist.

No, it's a massively bloated monstrosity that has no place in a well defined API.

jwenting 1,905 duckman Team Colleague

"Action figure" is only a marketing term used to sell dolls to boys.

uh, I see precious few girls interested in GI Joe play sets, and very few healthy boys fooling around with Barbie dolls wearing pink dresses...

jwenting 1,905 duckman Team Colleague

good luck!

jwenting 1,905 duckman Team Colleague

There's ample evidence that "gender specific toys" are far from evil, they're natural.

As late as last year there was for example a study where newborns and toddlers were placed in a room and allowed to choose their own toys.
Girls ended up choosing dolls, boys ended up choosing traditional "boy toys" like action figures.
Also, boys were more likely to select blue toys, and girls pink toys, even among newborns that had never been presented with those colours in their environments.

As to smartphones: certainly not. Let children be children and play with child toys.
They don't need smartphones, with all the stuff they can run into on the net (let alone the associated cost).
Children should not have unmonitored internet, certainly not until they're 15 or so years old and know the ropes. And that means no internet access without a parent or teacher sitting next to them.

jwenting 1,905 duckman Team Colleague

and oh, make sure to do all that while you're not connected to any network, including the internet.
Physically unplug network cables and turn off WiFi hotspots.

jwenting 1,905 duckman Team Colleague

Sure way to ensure data is irretrievable is what I saw in actual use at a major bank: shred the hardware.
Seen those big shredding machines for turning large tree limbs into wood chips (also used to shred plastic and metal for recycling)?
That's the machines you want. Turn them on, set at a nicely small granularity (say half a centimeter), enter the disks (and other components, like CPUs, motherboards, network cards) into the hopper, and stand back.
The resulting fragments are guaranteed to be impossible to turn back into a working device (and if you're more paranoid still, add an oven and melt them down).

jwenting 1,905 duckman Team Colleague

Nothing wrong with Microsoft products, but don't stare blindly at any one product when building experience.
If you want to switch jobs, and there's an offer open using something else that you wouldn't mind learning, jump on it and broaden your horizons.
And there's always work for people who know Oracle well :)

jwenting 1,905 duckman Team Colleague

however, 1.441 will AFAIK box to a Float, not a Double.
150 might box to a Byte.
This is of course a specific problem here because of the use of hardcoded magic numbers rather than fields, and not having those magic numbers forced to a specific type.
Forcing double through 1.441d and int through 150i would prevent any such issues.

jwenting 1,905 duckman Team Colleague

hmm, I'd make some small changes to the User class as well.
Declare the data fields to be final, and declare the constructor arguments to be final as well.

If it were a realistic User you'd also not have a getPassword() method but a validatePassword(final Object candidate) method that simply returns whether the candidate password is valid in relation with whatever is stored on the User instance (in its simplest form that'd be a String comparison, but it doesn't have to be).

jwenting 1,905 duckman Team Colleague

he's waiting for the pin to drop...

jwenting 1,905 duckman Team Colleague

I think you missed the intent of your teacher which is for you yourself to come up with an idea rather than to just browse the internet and ask others to think for you.

jwenting 1,905 duckman Team Colleague

or not create an FB account in the first place. Just keep running into them when redirected automatically from other pages to such FB crap...

jwenting 1,905 duckman Team Colleague

If you use something from a newer version of Java it might not work on some machines running an older runtime. I ran into this in my Java class.

which has nothing at all to do with being multi platform or not, but with forwards compatibility.
It's like saying you're surprised that your C++ program compiled against Windows 8 and using Windows 8 specific API calls doesn't run on Windows 3.0.

jwenting 1,905 duckman Team Colleague

database program for a school small and big, which i use c++ or java?

what your teacher tells you to use.

jwenting 1,905 duckman Team Colleague

@Dani if you can't even see what the offers are... They're fishing for likes just to get higher FB rankings. No different from buying likes from clickfarms IMO.

jwenting 1,905 duckman Team Colleague

Seeing them used for corporate advertising. "Like us to see our special offers", etc..
Dishonest.

jwenting 1,905 duckman Team Colleague

never heard of any database engine giving as an error "the database has stopped unfortunately".
Again, list the actual error...

jwenting 1,905 duckman Team Colleague

it won't be, he's just a spammer...

jwenting 1,905 duckman Team Colleague

both Mario and Tetris are registered trademarks, so don't use the names or artwork in your own project...

jwenting 1,905 duckman Team Colleague

There's now facebook users who won't let you even view their pages unless you "like" them first.
And you wonder what's wrong with Facebook?

jwenting 1,905 duckman Team Colleague

depends on how long you'll be on that boat :)
And it's a conundrum. If you're going to be there long you're going to need many books but won't have room to stash them because it's needed for food.
Solar charger for the Kindle might be a better option...

Of course you can use the books for toilet paper, not so easy with a Kindle I've been told.

jwenting 1,905 duckman Team Colleague

ah, I much prefer everything in capitals rather than lowercase if we're going to use underscores between words.
Anyway, it's not USER_NAME but USERNAME, single word.
USERID or USER_ID, your choice.

jwenting 1,905 duckman Team Colleague

yay, I'm now "kewl" for never having got on the facebook bandwagon...

jwenting 1,905 duckman Team Colleague

making any assumption about equality between floating point numbers is a mistake.
http://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html read this for the nitty gritty details.

To summarise: it's impossible to map a floating point number with exact precision, therefore all you'll ever get is an approximation.
How good an approximation depends on hardware, operating system, and the phases of the moon and stars (well, not really that, but there's randomness involved).

That's why you should never compare floating point numbers for identity.
If you need to compare them at all, compare them to be identical within a specific accuracy range, say +/- 0.001 (or whatever you require, but the more accurate you expect things to be, the bigger the chance that you're going to reject things that you shouldn't).

And that's why in any serious calculations where precision is required, floating point numbers are not used.
Instead use integer mathematics or fixed precision numerical computation libraries, and only convert to floating point (if at all) for final presentation.
For example, an amount of money can be represented in dollars and cents as a floating point number, but is far better represented as an integer number denoting cents (as $1 is 100 cents).
Your more precise, and as an added bonus your calculations are faster as well.

jwenting 1,905 duckman Team Colleague

might help if you tell us what the error is...

jwenting 1,905 duckman Team Colleague

You should ask your teacher, not us, what the scope and requirements of his course work are.

jwenting 1,905 duckman Team Colleague

Any well rounded programmer should know at least C and Assembler. And can't go wrong knowing a bit of Cobol.
But maybe I'm old fashioned :)

jwenting 1,905 duckman Team Colleague

There is no "best".
Therefore asking for "the best" is a by definition useless exercise.

There might be something that's more appropriate for specific purposes in specific scenarios than something else, but you never tell us what your specific scenario is so again it's impossible to answer your question.

Ruby and Python are pretty similar in their capabilities, so it's mostly a question of individual preference combined with integration with whatever other tools you have selected to use.
For me, that means Ruby is overall the more likely option when and if I need a scripting language, simply because I have the infrastructure to support it already in place.

jwenting 1,905 duckman Team Colleague

finding all that out is part of your work, not ours. You should have learned how to perform your own research by now, make use of those skills.
Feel free to bounce ideas off of people, but don't expect them to do your thinking for you!

jwenting 1,905 duckman Team Colleague

Visual Studio has a lot of very useful features, but most only become useful in fairly large products with multiple developers working on it as a team, and of course a lot of things only come into play for specific types of applications like web applications.

jwenting 1,905 duckman Team Colleague

think I still have one of those, in an old machine I've never gotten around to dismantling and and destructing :)

jwenting 1,905 duckman Team Colleague

coders aren't the ones inventing business plans.

There's a lot of ideas out there, problem is getting funding. You might have noticed the world's in a bit of an economic slump, which isn't helping to get investment capital for radical new business ideas.

jwenting 1,905 duckman Team Colleague

yes, and Eclipse isn't known for being friendly to your memory OR your CPU.
If he's running a machine with 32bit Win7 and only 2GB RAM, his CPU will also be very, very marginal (and that's putting it mildly).
Most likely it's a Core2Duo, and an older moderl. Such machines are designed to run XP or at best Vista, not Win7. It's specs that were decent but not stellar 10 years ago.

jwenting 1,905 duckman Team Colleague

he's the one who cherry picked unrelated factoids to come up with a lie though...

jwenting 1,905 duckman Team Colleague

nope. Maybe there's multiple Mikes here though and you misunderstood which I'm addressing :)

jwenting 1,905 duckman Team Colleague

first usually is used to set conditions that have to be met for something to happen, second describes the event itself.

Of course the language is often so completely butchered that in reality many people use both interchangeably.

jwenting 1,905 duckman Team Colleague

all of which means nothing at all, Mike. You claimed the main reason people buy guns for is to commit suicide.
That's such a blatant lie you can't even come close to finding a statistic you can massage into shape to show some sort of correlation.
So you come up with numbers that claim that 60% of suicices involve a firearm, then combine those with some utterly meaningless numbers that are over a decade older that a percentage of gun deaths to be suicides (go figure), and then combine that with an even older unreferenced claim that homes with a gun are more likely to see a suicide than homes without one.
Not only are all those claims irrelevant to the actual claim you make, they're also unrelated to each other as they apply to different time periods.
With 200 million guns in the US (the actual figure is closer to 300 million), and some 3 million deaths a year TOTAL in the country, which is lower than the number of guns sold per year in the US, every single death according to your logic would have to be a suicide by gun, and a suicide by a newly purchased gun at that, for your argument to make any sense at all.

So much for unusual facts. Usual lies more likely.

Unusual fact: It's been statistically shown that 96% of statistics are incorrect.

jwenting 1,905 duckman Team Colleague

floating point == rounding errors...

jwenting 1,905 duckman Team Colleague

and how are you going to "detect it is faultless" anyway? Do you have perfect understanding of what it's supposed to do under any and all conditions, expected or otherwise?
And can you describe that knowledge mathematically in such a way that you could create a test that incorporates all those scenarios yet runs in a finite amount of time?
And how are you going to guarantee that that test itself is not flawed?

No, you can't ever get to a state where you can claim your program is faultless, in other words perfect.
At most you can get to a state where you can claim that you've exhausted all reasonable means to asserting that it will run nominally under a given set of conditions, then describe those conditions.

jwenting 1,905 duckman Team Colleague

OK, now go ahead and use what you've been taught.

jwenting 1,905 duckman Team Colleague

You are asking if just writing software can open your computer to external malware?
No, it doesn't.

Of course if you write software that goes out and downloads and runs stuff from around the net without your control when you run it, it might download and run anything at all.

Just run your system using the normal security precautions that you'd use at any time and you're no more at risk than at any time (and how much that is is impossible to tell without knowing what precautions you normally take, if all you do is browse stackoverflow and daniweb for information while running a firewall and AV package you're a lot less at risk than if you're downloading stuff from every anonymous website and p2p network you come across and running it without any security in place at all).