Hard Light Productions Forums
Off-Topic Discussion => Programming => Topic started by: Polpolion on August 23, 2008, 06:44:21 pm
-
I'm taking an AP Java course this year in school, but there's only one programming teacher on campus and she doesn't teach. What's the best way to teach myself Java short of enrolling in more classes somewhere else?
-
Read "Java 2 for Dummies"
-
how can she be a teacher if she does not teach? i thought that was a prerequisite.
-
heh... sadly, it's not
-
Figure out what you need to know for the class and make a program using it. For the Java class I took, that was mostly classes, polymorphism, inheritance, methods, variables, arrays, strings, loops, control statements, return values, references, AWT, Swing, recursive functions, and basic file I/O. Also key built-in things like MouseEvents, ActionEvents, Graphics type and drawing using it, vectors and other list types. Multithreading would also be a good start. We didn't cover exceptions very much IIRC, but they are a critical part of the language and would be good to learn (They're absolutely vital, really).
According to one of my math professors during lecture, Nobody ever taught anybody anything.
-
<quote>According to one of my math professors during lecture, Nobody ever taught anybody anything.</quote>
I'd most certainly agree with that, to be honest, particularly in a University environment, you shouldn't be taught, really, you should more be given guidelines towards what you need to learn. Unfortunately, a lot of studying I've encountered involves, in essence, teaching people the answers to the exam questions, which isn't really the same as learning the subject.
-
Well if you ever need any small assignments to make just let me know... learned Java a year ago have alot of the small assignments still
But well to be honest the thing ive got the most out off while learning Java is just making a decision to make a program that can do somthing specifik and then find out how to do it... the best "tool" to learn Java seems to be www.google.com since almost evrything have an reply there...
if you ever get any problems with somthing not working as intended or stuff like that ask away (hopefully with source code attached :P)
Sincerly
HE
-
Yes, I'm sure I want to reply....
I too, am learning Java, but just from a learn java book. I am only on the second program, and already can't figure out what I'm doing wrong. Can you tell me why this is giving me an "else without if" error?
// get input
import javax.swing.*;
//class name
public class Password
{
//main method
public static void main (String[] args)
{
//here's the input
String input;
//where you type
input = JOptionPane.showInputDialog("What's the password?");
//see if it's right
if(input.equals("opensesme"));
{
//it's right!
System.out.println("You may pass.");
}
//but if it's wrong
else
{
//it's wrong
System.out.println("You chose ... poorly.");
}
}
}
-
Remove the Semi-Colon from the end of the If statement, that's what's causing the problem :)
-
Yep, that's it, thanks.