|
|
Croatia9455 Posts
You can set an Environment Variables by clicking right click on My Computer -> Properties -> Advanced.
Let me get back to you on exactly how to set up Java variables, because I did it like a year ago and kinda forgot now ^^.
EDIT: oh yeah, you need to set path to the Java executables. Under those Environment Variables, find Path variable under System Variables and click edit. Add semi colon at the end and type the path to your Java folder where the executables are. Example: If you installed your Java to "c:\Program Files\Java", then you add to the path variable ";c:\program files\java\bin" (note: I think executables are in bin folder, but you should check just to be sure)
|
|
Croatia9455 Posts
And yeah, you should install some IDE (jGrasp is pretty simple).
You only need to edit your environment variables if you're gonna compile from command prompt, but with IDE there's no need for this.
|
Kyrgyz Republic1462 Posts
On January 30 2011 08:21 Qzy wrote:Hi You should get an IDE. Like Netbeans or Eclipse - They control everything for you and makes it simple. . From there, try an online tutorial for java? http://www.tutorialspoint.com/java/index.htm
I would not recommend jumping into an IDE straight away though. I think it is quite helpful to understand how the whole chain of Java development process works, especially things like setting up the class path. An IDE would do that for you and that's cool, but then you will have a hard time trying to run your program without one, and that makes you feel quite stupid
|
You should just use a very simple IDE like JCreator LE. This way everything can be compiled, easily checked for syntax errors and such. After that you should use Eclipse, which I find has better functionality but JCreator is very newbie friendly. Never tried Netbeans though, but its a whole package IDE.
Im not very experienced since Ive only been doing this for a year, both C++/Java. D:
edit: Try using MS-DOS then, I would probably be stumped without a IDE.
|
ok im downloading netbeans at the moment apparently it is a pretty complete package.
i will check out JCreator LE
|
NONONONO NOT NETBEANS!!!
No, just kidding, it's not bad at all, but eclipse is so nice. It's very beginner friendly: has a red x mark if your code is wrong, green check if its right, auto suggests correction etc.
I use netbeans mostly for GUI stuff, the coding environment is worse.
|
netbeans is nice but it's buggy as fuck. I still prefer it over eclipse though.
|
On January 30 2011 09:08 fanta[Rn] wrote: netbeans is nice but it's buggy as fuck. I still prefer it over eclipse though. hi fanta sup?
|
Everyone uses Eclipse, hop on the bandwagon. Haha :D
|
Hyrule18937 Posts
I actually recommend learning C# instead. Java is bloated, and is up for some hard times.
|
If you want to start by learning, check out Blue Pelican Java - its a free java textbook
|
If you choose to use an IDE (you should), use IntelliJ. IntelliJ blows Eclipse out of the water in terms of usability and integration with other tools.
I use IntelliJ at home, and IDE at work because the corporate version is ridiculously expensive.
|
On January 30 2011 08:55 Coagulation wrote: ok im downloading netbeans at the moment apparently it is a pretty complete package.
i will check out JCreator LE
Nooooooooooooooo!!!!
If you are starting, do not use an IDE. You have to learn how to set things up.
Besides that, if you are just gonna code simple programs, there is no need to fire up a whole IDE and start coding when you could just open a terminal and notepad.
When you have the need to develop a GUI that demand too much repetitive coding, then use an IDE.
|
Don't listen to these guys saying not to use an ide. If you've never programmed before, your goal isn't to become a ninja yet, you just want to learn the basics... There can be done arcane wizardry required to compile and run programs for any language, and it's better to have a solid understanding of programming fundamentals before you start trying to figure that out too...
|
On January 30 2011 09:52 fabiano wrote:Show nested quote +On January 30 2011 08:55 Coagulation wrote: ok im downloading netbeans at the moment apparently it is a pretty complete package.
i will check out JCreator LE
Nooooooooooooooo!!!! If you are starting, do not use an IDE. You have to learn how to set things up. Besides that, if you are just gonna code simple programs, there is no need to fire up a whole IDE and start coding when you could just open a terminal and notepad.
If he is learning java for education he should learn the basics, yes. If he is learning java to learn an additional language or just start to learn programing, there is no need to code in notepad and compile it via command line.
An IDE is a good tool to keep track on what is working and what is not. Not to mention step by step debugging which made learning to program a lot easier. Why should he sacrifice this for some command line skills he won't need if he will never implement complex systems?
|
The error tracking is a good point, but here are my reasons for not using an IDE:
1. He would be using a bazooka to kill a fly (complete netbeans package will install so much stuff that he probably will never use) 2. Opening a terminal+notepad is way faster than Netbeans 3. He has everything he needs installed (the JDK), just need to set the Path, which was explained step-by-step above
|
On January 30 2011 11:00 fabiano wrote: 1. He would be using a bazooka to kill a fly (complete netbeans package will install so much stuff that he probably will never use) Is that really an issue? Most computers can handle it, right? So what's bad about installing much stuff you'll never use?
On January 30 2011 11:00 fabiano wrote: 2. Opening a terminal+notepad is way faster than Netbeans If i read the OP correct, he cannot code yet. He WILL make plenty of mistakes some of which are hard to figure out on the command line (java compiling errors and exceptions sometimes really suck ...). A step by step debugger will save him more time than opening all those netbeans sessions will cost.
On January 30 2011 11:00 fabiano wrote: 3. He has everything he needs installed (the JDK), just need to set the Path, which was explained step-by-step above See 2. It's not about being able to code with the current setup, it's about learning efficiently.
One things why java is so easy to learn is because of it's easy to setup IDEs that let you look into how and why the program works. Not to mention that most of the IDEs are free. If it weren't for that, c# would be just as good as a first programing language.
|
Ok, go with IDE then.
Hopefully you will see how much fun programming is!
Remember that many times you will find yourself stuck at something, like with the problem with Path you posted here, but by experience I can assure you these are the times you learn the most. This was a good time to learn what classpaths are, even if still don't know how to code
But if you are rushing to learn how to code, just go with IDE.
|
|
|
|