Login

Welcome, Guest. Please login or register.

April 27, 2024, 09:24:45 pm

Author Topic: Java Programming????  (Read 2155 times)  Share 

0 Members and 1 Guest are viewing this topic.

MagicGecko

  • Victorian
  • Forum Leader
  • ****
  • Posts: 506
  • W3$T $IDe I$ B3$T $!D3
  • Respect: +43
Java Programming????
« on: January 21, 2014, 02:12:30 pm »
0
I'm not sure if I even posted this in the right place but anyway

Hey everyone,
So I'm doing this subject in semester 1 but I am feeling pretty nervous about it. Unlike all my other subjects like physics, chem, math and bio I at least have some background knowledge from VCE but for programming? Nada.
What should I look out for? How should I tackle it?
Any advice from those who have some experience with programming will be greatly appreciated!
Thanks! :)
 
2013-2016:
Bachelor of Engineering (Biomedical)(Honours) @ RMIT


~Full-Time Biomedical Engineer~

"im not crying there’s just overpriced college education in my eye" ~ abigalmills-tumblr

Thu Thu Train

  • Voted AN's sexiest member 2012
  • Victorian
  • Forum Leader
  • ****
  • Posts: 667
  • <3
  • Respect: +336
Re: Java Programming????
« Reply #1 on: January 21, 2014, 02:27:43 pm »
+2
If its an introduction to programming in Java then they should assume that everyone is starting from a level where you have little to no knowledge of Java programming. If you're nervous about lagging behind or that everyone else have previous programming experience download an IDE such as eclipse and start going through the "official" Java tutorial also consider going to your universities library and see if they have any books on Java programming but everything in those books will be available online for free in other tutorials anyway.
        (
     '( '
    "'  //}
   ( ''"
   _||__ ____ ____ ____
  (o)___)}___}}___}}___}   
  'U'0 0  0 0  0 0  0 0    0 0
BBSN14

i actually almost wish i was a monash student.

MJRomeo81

  • Part of the furniture
  • *****
  • Posts: 1231
  • Princeps
  • Respect: +167
Re: Java Programming????
« Reply #2 on: January 21, 2014, 03:36:07 pm »
+4
Download 'Eclipse' as this is the IDE used at RMIT.

I suggest to start learning Java and "Object Oriented Programming" concepts. i.e. classes, objects, etc.

Start off with the traditional "hello world" program and then learn about different control structures. i.e. looping, if statements, etc.

The first year units will have you developing console programs (i.e. no GUI). Some starter code is for your below:

Code: [Select]
public class HelloWorld
{
  public static void main (String[] args)
  {
    System.out.println("Hello World!");
  }
}
Currently working in the IT Industry as an Oracle DBA (State Government)

Murphy was an optimist

Bachelor of Information Technology @ La Trobe (Melbourne) - Completed 2014
WAM: 91.96
The key, the whole key, and nothing but the key, so help me Codd.

Subjects I tutored during my time at LTU:
CSE2DBF (Database Fundamentals)
CSE1IS (Information Systems)
CSE2DES (System Design Engineering)

Quote
“If I had an hour to solve a problem I'd spend 55 minutes defining the problem and 5 minutes thinking about solutions.”
― Albert Einstein

alchemy

  • Victorian
  • Part of the furniture
  • *****
  • Posts: 1222
  • Respect: +25
Re: Java Programming????
« Reply #3 on: January 21, 2014, 04:07:21 pm »
+2
I program in C++ mainly, but learning any programming language can be much the same for anyone;  there's ups and downs but it's the resilience that counts in the long run. I suggest building this quality early on (perhaps even before you start the course).

How do you build resilience? I'm not sure if your course would involve 'algorithms and data structures' but nevertheless, I found that practice in problem solving (much like maths) was what helped me improve. I'm currently training for the AIO: http://orac.amt.edu.au/aioc/train/
Have a look at problems at that site if you want to begin algorithmic problem solving. The problems range over a reasonable level of difficulty.

Remember that sometimes sticking your head in a book isn't the best way to go. I read the first chapter in a C++ book proclaimed to be "awesome" but got bored after the first chapter. So stay away from books if you don't like them.

If you don't mind me asking, what made you want to do this course? I applaud you for choosing it btw.

MagicGecko

  • Victorian
  • Forum Leader
  • ****
  • Posts: 506
  • W3$T $IDe I$ B3$T $!D3
  • Respect: +43
Re: Java Programming????
« Reply #4 on: January 21, 2014, 05:11:19 pm »
0
Thank you everyone for your advice! I will definitely download eclipse and go through it!

If you don't mind me asking, what made you want to do this course? I applaud you for choosing it btw.
lol I don't have the option of choosing which courses I get to do, my program coordinator made my timetable and it happened to include programming, I wish I could choose my courses! Though I do see the relevance of programming in my program so i'm not complaining :)
 
2013-2016:
Bachelor of Engineering (Biomedical)(Honours) @ RMIT


~Full-Time Biomedical Engineer~

"im not crying there’s just overpriced college education in my eye" ~ abigalmills-tumblr

Aaron

  • Honorary Moderator
  • ATAR Notes Legend
  • *******
  • Posts: 3932
  • Respect: +1536
Re: Java Programming????
« Reply #5 on: January 21, 2014, 05:20:24 pm »
+4
Agreed with MJRomeo here. Start off with the basics and work your way up. Not sure if this is the required text or not but the Absolute Java textbook is very good at explaining concepts. If you can problem solve and are dedicated to learning this language, then there will be no problems at all. It's very flexible in terms of what you can do - in the sense that there is no "one correct answer".

I would start off by viewing some basic online tutorials for Java (such as TutorialsPoint) which goes through from basic to advanced Java, and test out sample programs and try writing a few of your own using an IDE (Eclipse has been mentioned but there are others which you can use - I personally don't prefer Eclipse).

My main advice would be not to give up when it gets difficult and just try it! It takes a while to get used to but once you're used to it, it makes things much easier! Be careful and watch out how you type things - because one spelling mistake and the entire program starts to error, so it's important to watch out for that as you go. Lots of people find programming to be quite intimidating but it isn't once you grasp what is required. It involves creativity and planning

For example: A basic shop (cash/change) calculator which has 2 inputs required from the user - amount and cash. You can then think about well, what calculations are required? what's needed? A simple format is like so:

Simple Shop System using one class
Copy and paste this into a suitable IDE and see how this operates - as an example (name file Shop.java)

Code: [Select]

import java.util.Scanner; // A scanner is required for user input from the keyboard

public class Shop { // name of the .java file usually (e.g. Shop.java)

  public static void main(String[] args) { // the main method - required

  Scanner kb = new Scanner(System.in); // declare a Scanner so we can input via keyboard.

  System.out.print("Total amount (in $): "); // ask the user for an input (amount of items)
  double amount = kb.nextDouble(); // save the input to a variable called amount (cannot be int, could be a decimal value!)

  System.out.print("Enter cash given (in $): "); // ask the user for another input (cash given by the customer to the attendant)
  double cash = kb.nextDouble(); // save the input to a variable called cash of type double (cannot be int, could be a decimal!)

  // calculate change required now
  double change = cash - amount; // you could incorporate this in the println statement, but this works just as well

  System.out.println("Change required: $" + change);

  /* the plus sign is to indicate concatenation. Concatenation means joining together. We cant include it in the "" because change is not a string, it is a variable therefore it needs to be included in the print but as a variable, not a string. */

  }

}


Expected output (using Netbeans)
You could fix it up to remove the repetition of 9's, but that would be diving deeper.

Code: [Select]
run:
Total amount (in $): 6.95
Enter cash given (in $): 13.20
Change required: $6.249999999999999
BUILD SUCCESSFUL (total time: 4 seconds)

All the best with this subject. :)
« Last Edit: January 21, 2014, 06:52:25 pm by Aaron »
Experience in teaching at both secondary and tertiary levels.

website // new forum profile

alchemy

  • Victorian
  • Part of the furniture
  • *****
  • Posts: 1222
  • Respect: +25
Re: Java Programming????
« Reply #6 on: January 21, 2014, 06:17:35 pm »
0
Netbeans is a good IDE for Java, I believe.