aspose file tools*
The moose likes Beginning Java and the fly likes What are some useful exercises for learning Java on a basic level? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "What are some useful exercises for learning Java on a basic level?" Watch "What are some useful exercises for learning Java on a basic level?" New topic
Author

What are some useful exercises for learning Java on a basic level?

sean parsons
Ranch Hand

Joined: Oct 18, 2010
Posts: 34
If there are any exercies that now certified Java programmers did that allowed them to learn quicker, i would like to know of them please. Thank you greatly!


Wants to change the world....
Mohamed Sanaulla
Saloon Keeper

Joined: Sep 08, 2007
Posts: 3056
    
  33

I would recommend to try to put the concepts learned into code- that way the concepts will persist for a longer time. Also let us know which material you are referring for your study. Usually all of them provide sample programs. Also you can try solving the problems on: http://projecteuler.net/

Also you could try referring to: Head First Java- which has lot of interesting exercises.


Mohamed Sanaulla | My Blog
Bobby Smallman
Ranch Hand

Joined: Sep 09, 2010
Posts: 107
Thanks for the link to Project Euler! I don't know how I have never heard of it before! Came to this thread to help the original poster and found out a bout a sweet website instead!


Everyday in every way, we get a little better.
sean parsons
Ranch Hand

Joined: Oct 18, 2010
Posts: 34
I am reading Head First and it is a great book, i was just wondering if theres any way to speed up the learning process, get the mind really going.
Stephan van Hulst
Bartender

Joined: Sep 20, 2010
Posts: 3378
    
    9
I have used this tired example a lot of times, but I think it's great as a starter.

First, make a tic-tac-toe game that will accept input from the keyboard, and each turn prints the board to the console.
Enhance the game by adding an artificial intelligence.
Further improve the program by adding a GUI.
Finally, add support for LAN games.

This single program teaches you a lot about basic design, MVC patterns, Streams and other I/O, and even Threads (tip: when you're designing LAN support, make it so that you can also chat with the other player asynchronously).
sean parsons
Ranch Hand

Joined: Oct 18, 2010
Posts: 34
I wish i was on any level to even try to do something like that, i would have to complete Head First Java and understand it, complete and understand are two things but i will attempt to make one as soon as i feel capable.
Stephan van Hulst
Bartender

Joined: Sep 20, 2010
Posts: 3378
    
    9
That's the point. You have to work on something that at first may seem it's a little bit too much. Of course you have to stay realistic, but I'm pretty sure you should be able to at least think about how to make a basic Tic-Tac-Toe for console.

The point is that not knowing how to do something makes you research into how you *could* do it. This is how you learn.

Here is a tip to get your started (assuming you are interested in doing this thing). Make a Board class, and think of what a user would want to do with a Board. Add methods that will allow a user to interact with the board: find out which squares are taken by which player, occupy a square, determine if there is already a winning combination on the board, determine if there is a stalemate, etc.

If you have questions, you can show us how far you have come, and which parts you are stumbling over.
Mohamed Sanaulla
Saloon Keeper

Joined: Sep 08, 2007
Posts: 3056
    
  33

sean parsons wrote:I am reading Head First and it is a great book, i was just wondering if theres any way to speed up the learning process, get the mind really going.


Take your time, let the concepts sink in. And Head Frist Java itself has a complete application which is developed step by step in each chapter. I would say you complete the book, understand the concepts. Speed up would depend on how many hours your can be focussed But I would say- Get fascinated by the Java applications around, get inspired so that you can strive harder to really reach that level of expertise.

Also as Stephan said- you can actually think of certain application which you might want to develop. Head First Java has a really good application being developed- Some music player or something (cant recall)- The authors- step through the development of the application component by component- adding new feature in each chapter.
Mohamed Sanaulla
Saloon Keeper

Joined: Sep 08, 2007
Posts: 3056
    
  33

Bobby Smallman wrote:Thanks for the link to Project Euler! I don't know how I have never heard of it before! Came to this thread to help the original poster and found out a bout a sweet website instead!


My pleasure I have started to use the problems posted on the site as a means to learn the Language(Scala). Just reading through the Syntax wasnt sinking the concepts. This is kind of helping me I guess There's another one: http://codekata.pragprog.com/ I see its not being updated, but has a few problems posted there as well. Another popular coding platform: http://www.codechef.com/ (the level of problems are slightly on the higher end)

sean parsons
Ranch Hand

Joined: Oct 18, 2010
Posts: 34
That will be my next project! il be sure to ask for help when i get stuck.

Stephan van Hulst wrote:That's the point. You have to work on something that at first may seem it's a little bit too much. Of course you have to stay realistic, but I'm pretty sure you should be able to at least think about how to make a basic Tic-Tac-Toe for console.

The point is that not knowing how to do something makes you research into how you *could* do it. This is how you learn.

Here is a tip to get your started (assuming you are interested in doing this thing). Make a Board class, and think of what a user would want to do with a Board. Add methods that will allow a user to interact with the board: find out which squares are taken by which player, occupy a square, determine if there is already a winning combination on the board, determine if there is a stalemate, etc.

If you have questions, you can show us how far you have come, and which parts you are stumbling over.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: What are some useful exercises for learning Java on a basic level?
 
Similar Threads
WSDL Reference in generated Client Stub.
Instance Variables
Urgent sqlj question
SCJP
Stop creating object