We hope you enjoy your visit.

You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.


Join our community!


If you're already a member please log in to your account to access all of our features:

Username:   Password:
Add Reply
Java; just learning it
Topic Started: Sep 15 2005, 01:55 PM (198 Views)
Multikill
Member Avatar
SLAYER EATS PLATIPUS?!?!
[ *  *  *  *  *  * ]
public class Text1{
public static void main(String args[]){
String myMessage;
myMessage="This is a local variable.";
System.out.println(myMessage);
}
}



Well I've just started my AP computer science and we have to learn java abd be able to use it on our own by the end of the year. Here's what we copied down.

I just want to verify that I know what I'm talking about.
In line three thats just declaring that I'm going to use a variable named myMessage right?

and after I'm defining my variable with text. I'm new to variables so I just want to make sure I have the right concept.
Offline Profile Quote Post Goto Top
 
RagingFuryBlack
Member Avatar
Member
[ *  *  *  *  *  *  * ]
Multikill
Sep 15 2005, 01:55 PM
public class Text1{
public static void main(String args[]){
  String myMessage;
  myMessage="This is a local variable.";
  System.out.println(myMessage);
}
}



Well I've just started my AP computer science and we have to learn java abd be able to use it on our own by the end of the year.  Here's what we copied down.

I just want to verify that I know what I'm talking about. 
In line three thats just declaring that I'm going to use a variable named myMessage right?

and after I'm defining my variable with text.  I'm new to variables so I just want to make sure I have the right concept.

I'll break it down for you.

Quote:
 

public class Text1 Class Decleration
{
  public static void main(String args[])Main Method
    {
  String myMessage; Vairable Decleration
  myMessage="This is a local variable.";Variable is Instantiated, and assigned a value
  System.out.println(myMessage);Outputs the variable myMessage and then breaks to a new line
      }
}
Offline Profile Quote Post Goto Top
 
Multikill
Member Avatar
SLAYER EATS PLATIPUS?!?!
[ *  *  *  *  *  * ]
kewl, I thought I knew somewhat what I was doing.
Offline Profile Quote Post Goto Top
 
RagingFuryBlack
Member Avatar
Member
[ *  *  *  *  *  *  * ]
Multikill
Sep 15 2005, 02:51 PM
kewl, I thought I knew somewhat what I was doing.

If you need any help, feel free to MSN me. I may ask to steal your ap notes though :P
Offline Profile Quote Post Goto Top
 
Multikill
Member Avatar
SLAYER EATS PLATIPUS?!?!
[ *  *  *  *  *  * ]
heh ok :P XD

We've just started with variables. Its amazing how many people are in that class who have NO clue.
Offline Profile Quote Post Goto Top
 
RagingFuryBlack
Member Avatar
Member
[ *  *  *  *  *  *  * ]
Multikill
Sep 15 2005, 03:14 PM
heh ok :P XD

We've just started with variables. Its amazing how many people are in that class who have NO clue.

My school requires both taking intro to java and visual basic before taking AP
Offline Profile Quote Post Goto Top
 
MrsSim
Member Avatar
Splendiferous™
[ *  *  *  *  *  * ]
It's good that your learning Java. Once you've mastered this, you can go into the grandfathers of all coding languages: C, C++, and C#. Now those are pretty tough languages.

:ermm:
Offline Profile Quote Post Goto Top
 
RagingFuryBlack
Member Avatar
Member
[ *  *  *  *  *  *  * ]
MrsSim
Sep 15 2005, 06:21 PM
It's good that your learning Java. Once you've mastered this, you can go into the grandfathers of all coding languages: C, C++, and C#. Now those are pretty tough languages.

:ermm:

C# is easy, and C++ isnt that hard either. Havent tried C before though.
Offline Profile Quote Post Goto Top
 
catfriedrice
Member Avatar
Anatidaephobic
[ *  *  *  *  *  * ]
MrsSim
Sep 15 2005, 06:21 PM
It's good that your learning Java. Once you've mastered this, you can go into the grandfathers of all coding languages: C, C++, and C#. Now those are pretty tough languages.

:ermm:

to think I learned C++ and then Java. Now I'm into Javascript/ActionScript

For fun, go and download NetBeans for coding in Java. I recommend it.
Offline Profile Quote Post Goto Top
 
PWND!
What once was.
[ *  *  *  *  *  * ]
I'm doing C++ at the moment, and it's pretty easy really. I ahven't tried Java, but I'm going to be doing it soemtime soon.

However, if ou really want to delve into the mother of all programming, go learn Assembly. interesting stuff, very efficient, but hard to code. I'm teaching myself at the moment..
Offline Profile Quote Post Goto Top
 
catfriedrice
Member Avatar
Anatidaephobic
[ *  *  *  *  *  * ]
PWND!
Sep 15 2005, 10:20 PM
I'm doing C++ at the moment, and it's pretty easy really. I ahven't tried Java, but I'm going to be doing it soemtime soon.

However, if ou really want to delve into the mother of all programming, go learn Assembly. interesting stuff, very efficient, but hard to code. I'm teaching myself at the moment..

pretty easy? You haven't seen "Object Oriented Programming" yet, have you. The most feared part IMO
Offline Profile Quote Post Goto Top
 
PWND!
What once was.
[ *  *  *  *  *  * ]
Well, no, I haven't started on objects useing C++, but I ahve used them in other languages, so it shouldn't be that much of a death trap ;)
Offline Profile Quote Post Goto Top
 
catfriedrice
Member Avatar
Anatidaephobic
[ *  *  *  *  *  * ]
it's a deathtrap. Java OOP is a whole lot easier.
Offline Profile Quote Post Goto Top
 
PWND!
What once was.
[ *  *  *  *  *  * ]
:lol: I'll look fowad to it then. *hides behind .. QBasic?*
Offline Profile Quote Post Goto Top
 
1 user reading this topic (1 Guest and 0 Anonymous)
« Previous Topic · Technology Chat · Next Topic »
Add Reply