• Google+
  • Twitter
  • YouTube
  • RSS
  • Facebook

Latest Java and Programming Tutorials

C++Tutorial for Beginners 35 – The “this” Keyword; A First Taste of Pointers

The “this” keyword seems mysterious to beginners, but as we’ll see, it’s not at all hard to start us……..

C++Tutorial for Beginners 34 – Overloading Constructors
C++Tutorial for Beginners 33 – String Streams; Adding Number to Strings
C++Tutorial for Beginners 32 – Getters and Setters
C++Tutorial for Beginners 31 – Constructors and Destructors

You can now access ALL my premium courses for just $19 a month, cancellable anytime; no minimum period. Click here!

Free C++ video course: learn to program in C++ from scratch!

Java Spring Framework Tutorial

The Java Spring Framework Tutorial

My latest premium tutorial is an extensive introduction to the popular Spring Framework, including web programming with Spring MVC. $29.
My Kindle book about online teaching and my many attempts to free myself from office work … How to Make a Great Living Teaching Online

Java for Complete Beginners

Java for Complete Beginners

Completely free if you sign up via this link. Over 175,000 people have already joined this course on Udemy.com! Now available right here too. This course teaches you how to program in Java from scratch.
You can find lots more courses here

Want a Course but Can’t Afford to Pay?

If you want access to one of my paid courses but can’t afford to pay, email me at john@caveofprogramming.com with a brief email explaining your situation, and I’ll consider giving you free access.


If you feel like sending me some cash … well, thanks! You can do so right here:

Get a Job as a Software Developer

If you’re looking to get a job in software, my free Java for Complete Beginners is all you need, at the minimum. If you master the contents of this course and you’re prepared to travel and apply for lots of stuff, while there are no guarantees, you’ve got a good shot at getting a job as a programmer. This course includes advice about getting a job.

If you want to improve your chances by learning an advanced Java specialisation, my Servlets and JSPs (and JSTL) course gives you very marketable skills. You’ll need to separately study HTML and CSS a bit (not as hard as Java!) and preferably some SQL too.

Alternatively, you could Learn Android Programming or try Mastering Java Swing; Swing is widely taught in universities, but there are less jobs around for it than for web-based stuff (see Jobserve).

Finally, The Java Spring Tutorial gives you some very hot skills, but it’s advisable to learn about Servlets and JSPs first, unless you like being dropped in at the deep end.

My other free courses, Java Multi-threading and Java Design Patterns and Architecture, will certainly improve your chances in a job interview, and you can take them in whatever order you like.


Leave a Comment

  • Ivy October 21, 2014, 10:08 pm


    I saw your free course on Udemy and wanted to ask you if you would be interested in
    having that video posted on an non-profit organization website.
    Tools and resources such as yours is good foundation for self starters and
    people who want to learn.
    Please, visit the website and if your interested, you may contact me.

    Thank you,


    • John October 21, 2014, 10:35 pm

      Hello Ivy, you can post my free videos wherever you like. They are released on YouTube as Creative Commons.

  • Robert Lewis October 20, 2014, 3:53 am

    Hi John

    I just started using your tutorials on Java and you mention using HD. I can’t see a way to do that or don’t know how. Can you advise please.



    • John October 20, 2014, 4:22 am

      Hi Robert, if you’re watching on Udemy specifically, there is a HD button on the lower right when you start playing the video. This has to be clicked on. On YouTube, there’s a setting also in the lower-right, where you can switch to maximum bit rate (or whatever it represents), e.g 720.

  • Tim Smithers October 20, 2014, 12:51 am

    I have purchased your tutorials from udemy. The course do not complete on the udemy site. They load and then nothing. I would like to buy the courses directly from you. What should I do I contacted udemy but they refused to help. I hope you can help because I really enjoy your courses. I have the servlets and jsp, spring and swing.

    • John October 20, 2014, 12:54 am

      Hello Tim, thanks for buying. Are you using Chrome? They recommend it. I’m not sure why the courses wouldn’t work there for you, but I’ve subscribed you on my website too.

  • Keyhan October 17, 2014, 10:37 am

    Hi John I posted a question on Udemy, thought maybe you are not watching comments there so I add it here as well.
    This is regarding lessons 126 and 127.

    I have done the changes to the DB according to the lecture, but the thing is that when I want to create an offer I get an exception. The exception says the following “com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Column ‘username’ cannot be null”. When I come to think of it I really do not understand how spring could hook up the user with the offer when creating an offer? Can anyone explain?

    • John October 17, 2014, 10:47 am

      I’m watching it, don’t worry :) It notifies me once a day of the latest comments. It looks like you’re trying to create a row in the database, in the offers table, without specifying a username. This is what matches the offer to the user, so it needs to be specified in your SQL when you do the insert.

      • Keyhan October 17, 2014, 2:00 pm

        Yes, I understand that in the DB this is a way to find the relation between the two, but when you are doing a createOffer, how do you know which user you are, since it is not passed in by the form to the Service. The service just calls createoffer with an offer.

        In the OffersDao the statement for creating offers is “insert into offers ( username, text) values (:username, :text)”

        In the OffersDao there is also the getUsername() method that returns user.getUsername()

      • Keyhan October 17, 2014, 2:09 pm

        Eureka, I found the answer, it was in the controller…. now I see ;)

        • John October 17, 2014, 2:20 pm

          I was getting confused with my own tutorials there … yes, there’s a video called “Getting the username of logged in users” that covers this. I think at one point I refactor the database and test the database code, but then go on to automatically adding the user name later.

  • Yan Ji October 14, 2014, 4:31 am

    Hey John,
    I bought your spring video from udemy, but I can’t watch it on your website

    • John October 14, 2014, 9:40 am

      Hi Yan, can you watch it on Udemy.com? If you like I can give you a subscription to it on my website too … just create a free account there and let me know. john@caveofprogramming.com

  • Muhammad October 10, 2014, 4:05 pm

    Hi John, Im creating a chat app for android I want to get messages while app is closed.. I used a service to do that but my code stops when the app is closed .. Its not destroyed and i can see it in the running services.. I tried startService and bindService but It didnt work.. Thanks

    • John October 10, 2014, 7:38 pm

      Hi Muhammed, I must confess to not having done much with Android services, so can’t be much use. You can Google for the problem — I bet others have run into the same thing.

  • cris October 10, 2014, 3:25 am

    hi and thanks a lot for all the nice content you have and created for us! i was wondering if there was a web site or some place i could find exercises to practice from easy to medium all the way to expert where i would have problems to solve and create programs for each point being discussed in your tutorials! cheers and thanks in advance !

    • John October 10, 2014, 9:24 am

      Hi Cris, I hear codingbat.com is quite good! Also trying to invent and write your own programs is an excellent thing to do — you learn things that way that you could never learn from exercises.

  • chip sokear October 8, 2014, 8:04 am

    I have completed half of java for complete beginners. It’s really valuable.

  • Cesar Diaz October 6, 2014, 4:25 pm

    I like the way you explain the java course, I’m learning allot from it, I use NetBeans in stead of eclipse,but still well explain.

  • Sahil October 6, 2014, 2:07 pm

    Just wanted to appreciate your videos and teaching skills. Your tutorials are excellent!

  • Keyhan October 5, 2014, 8:56 pm

    Hi, I tried to find a contact mail from you so I could post a question about the Spring course I am taking right now.

    The thing is that I am in lesson 99 now and I thought to myself to move away from XML and the “Offers” Website with Servlet 3.x and Java config instead. I can create an account, write an offer and see available offers, but I cannot get the scuritysettings to work, I have created a speciall config for security and I have followed examples available online but they do not work for me. Now I was wondering if you have a version of your program written in Javaconfig instead of xml files?

    Best regards
    Keyhan H

    • John October 5, 2014, 9:01 pm

      Hi Keyhan, I’m afraid I don’t. I haven’t tried it. You could try turning on log4j debug for security and see what the output tells you. Probably it will give you some clue about what’s happening. john@caveofprogramming.com

  • kennedy September 29, 2014, 11:26 am

    can u recommend where i can learn java virtual using skype

  • kennedy September 29, 2014, 10:41 am

    i would live to learn java, ave already downloaded some of ur video on udemy their great i would like to be a proffesional programmer i have a bsc in IT but i concentrated more in networking and technical , do you offer virtual training using skype if u do how much do you charge

    • John September 29, 2014, 10:44 am

      Hello, I don’t offer it anymore, but you can learn everything you need to know from my video course. The main thing is to practise.

  • Muhammad September 25, 2014, 10:11 am

    Hey John..
    I have an android chat app, I use httpclient to get data from mysql through php, I have more than method for messages, friends, etc.. everything works fine but when I try to execute method inside another method in a for loop I get error..

    runOnUiThread(new Runnable() {
    public void run() {

    for (int i = 0; i getPhotoPath(msgs.get(x).getTitle());
    int pathsAfter = photo_path.size();

    if (pathsBefore != pathsAfter) {
    x ++;
    } else if (pathsAfter == friendsNames.size()) {
    Log.d(“Button Clicked”, “Paths After : ” + pathsAfter);


    Another Question :) .. How Can I stop a for loop like that I mentioned upper from inside it without doing i++ because it must be final.. :S or how can i stop thread from inside it ?
    I tried return but it will be in if statement so it didn’t work.. Thanks

    • John September 25, 2014, 10:20 am

      What is the error, Muhammad? It looks like you’ve got a bit missing from the for() bit. Return will stop your thread here, if your code is correct.

      • Muhammad September 25, 2014, 10:46 am

        When I try to execute method inside another method it doesn’t work.. I dont know why

        • John September 25, 2014, 3:49 pm

          You’re missing something from your code then! But your previous code looked like it had a syntax error in the “for”.

  • online it tutor September 24, 2014, 7:03 pm

    The effort of Sir, John is very well. Sir, John try to educate the community specially regarding the Java which seems he try seriously to express the experience to newbie’s. awesome effort…

  • Ralph Hosmer September 20, 2014, 8:09 pm

    This isn’t ‘your stuff’, per se, but I hope you can give me a suggestion:
    re: Oracle’s Java CheckBoxDemo
    I loaded it into Eclipse [it runs, but doesn't fine Icon Image].
    I set up a folder directory on my computer:
    On the Oracle site: I did a right-click on each of the geek images [ie: geek-cght.gif] and did Save-as to the geek folder on my computer
    In the CheckBoxDemo, I replaced the following [which includes my path address]:
    ImageIcon icon = createImageIcon(“C:\\Users\\Ralph\\workspace01\\images\\geek/geek-”
    + choices.toString()
    + “.gif”);
    I’ve tried both forward and reverse slash separators, but when I run, it throws an Exception:
    Couldn’t find file: C:\Users\Ralph\workspace01\images\geek/geek-cght.gif

    Any thoughts on what I’m doing wrong ??
    Thanks, Ralpjh

    • John September 20, 2014, 8:52 pm

      Hello Ralph, You have a forward slash mixed into your file path there, if you look closely.

      • Ralph Hosmer September 21, 2014, 9:56 am

        Corrected the ‘/’ AND:
        // Original
        if (imgURL != null) {
        return new ImageIcon(imgURL);
        BufferedImage img = null;
        try {
        img = ImageIO.read(new File(path));
        } catch (IOException e) {
        // TODO Auto-generated catch block
        System.err.println(“Could not find file: ” + path);
        Replaced ‘imgURL’ references with: ‘img’

        MAGIC: CheckBoxDemo now WORKS using my Local System IMAGES !!
        Thanks for your help, Ralph

  • L Herron September 18, 2014, 6:26 pm

    Hello John,

    Just wanted to say thank you for the tutorial on .equals() and what it means. Now I know how to answer if the question comes up in a job interview. As a female aspiring programmer, I think the advice that you’ve given will really help me greatly during my job search.

    • John September 18, 2014, 7:28 pm

      Glad it was helpful, and good to hear of a woman interested in programming! I think 90% of the people who watch my videos are male.

  • Rohit September 18, 2014, 12:09 pm

    I John,

    I just completed your course “Java for Complete Beginners” on udemy.com.I found it really helpful and it gives a good basic understanding of Java.Thanks for sharing all these knowledge with us!!!

    • John September 18, 2014, 12:13 pm

      Great to hear, Rohit! I hope you’ll enjoy putting your new skills to good use :)

  • kombo September 18, 2014, 5:23 am

    very good site..am very much impressed

  • Syed Umair September 17, 2014, 3:30 pm

    Hello John,
    Please tell me which course should I take after I complete “C++ for beginners ” and “Java for Complete Beginners”. So that I will be able to make Android apps (Games and other useful apps)all by myself..


    • John September 17, 2014, 3:55 pm

      Hi Syed, for Android you don’t need C++, only Java. I have a course on Android, but it only goes a little bit into games. You might find it helpful to get the basics of Android though. Other than that, maybe Google for Android games engines, e.g. AndEngine, and find some tutorials on them. It’s much easier to write games in Android if you use a framework, which you can download for free.

  • Ralph Hosmer September 16, 2014, 7:07 pm

    FYI, don’t bother spending more of your time. I made the change you suggested, and it helped, but still got ‘0 length’ on some sites. I ‘fiddled’ around some more and, at least. got different results. I’ll probably continue to ‘fiddle’, and here is the latest [FYI]:

    // Lecture 64: ‘Java for Beginners’ 16-Sept-2014
    // Output after deleting ‘www’ from URL name, per input from JOHN
    // Output with Buffered Reader and
    // ‘System.out.println(html.length());’
    // ‘//System.out.println(html);’
    //69451 [http://caveofprogramming.com]
    //0 [http://facebook.com/caveofprogramming] * (1)
    //156814 [http://news.bbc.co.uk]
    //0 [http://mail.yahoo.com] * (2)
    //269032 [http://theblaze.com]
    // * (1) Guess: have to be signed into Facebook first?
    // ………. It did not help to sign into Facebook first
    // …. Change URL to”http://facebook.com” and sign into Facebook first:
    // ………. It did not help
    //0 [http://facebook.com]
    // * (2) Giess” Change to “http://yahoo.com”? Now WORKS
    //1450 [http://yahoo.com]

    // Output after above changes:
    //69451 [http://caveofprogramming.com]
    //0 [http://facebook.com]
    //156165 [http://news.bbc.co.uk]
    //1450 [http://news.bbc.co.uk]

    Thanks again,

    • John September 16, 2014, 7:23 pm

      It’s no problem! Sites that require a log in, you’ll have problems with. Java is in effect a separate browser to whatever other browser you’re using, so logging in in a browser won’t help. It is possible to log in to a site with Java, but require further code. Some sites may not display unless cookies are enabled, which again require some extra code (but not much).

      • Ralph Hosmer September 16, 2014, 9:02 pm

        Thanks for all the help, and for a really interesting and educational course.
        ps: I’m also in the middle of a 4-course series on AstroPhysics @ edx.org from the Australian National University [anuASTRO1x, 2x, 3x and 4x]. It’s not in my educational field [BSEE MichiganTechnologicalUniversity: 1961], but I find it vary interesting and recommend you try it [Free to audit] if you want to go ‘outside your box’.
        Thanks again,

        • John September 16, 2014, 9:16 pm

          Cheers Ralph. I studied theoretical physics, so it might be a bit in my box. But then I did almost fail altogether, so could be somewhat outside my box also …

  • Ralph Hosmer September 15, 2014, 4:38 pm

    I’m taking ‘Java for Beginners’ and have completed thru Lecture 64: Implementing Iterable. I’ve got working code, but the HTML Length Outputs:
    java.net.ConnectionException: Connection refused: connect
    …. the rest of the Stack ..

    My guess is that I’m in the USA and these sites are whereever was handy for you. .. Timeout: waiting for connect
    SUGGESTION: If the Lecture is ever edited: Add some kind of comment [written or verbal] about this possibility, and if your enthusiasm holds up, show us a way around the problem.
    When I changed the UrlLibrary to USA sites, I still sometimes get a 0 length, but I don’t get the ConnectException thrown.
    Thanks for a very informative course,

    • John September 15, 2014, 9:07 pm

      Hi Ralph, this really shouldn’t happen — I wonder if you are using a proxy or have some intermittent Internet problem? If a browser can access websites, so should Java be able to … I wrote this code in Hungary, so not in the UK … I would find it extremely strange if Java cannot connect to UK sites from the US. Using this code, I can download from any site in the world that I’ve tried so far — cnn.com, for example.

      • Ralph Hosmer September 16, 2014, 12:01 pm

        Hi John,
        I’m a ‘user’ of the internet. My ISP is Time-Warner and I use their cable modem and my Belkin router {just for added firewall protection} connected to my HP 500-314 computer (purchased this year). Beyond that, I’ve not yet attempted to build a web-site, and my internet usage is browsing, Yahoo Email, on-line banking, taking courses {ie: Java for Beginners} and watching online Programs (ie: http://video.theblaze.com}. I don’t know about the inner working of the internet, and I wouldn’t know a ‘proxy’ if I saw one. My question was more of a curiosity question (why length = 0 when I use the sample program in this course trying to access different URLs). If I ever do attempt to build a web-site (which is not totally out of the question) I’ll have to educate myself. Any insights you can provide would be appreciated.

        • John September 16, 2014, 12:20 pm

          I’m clueless, Ralph … there’s no reason here that I can see, why it wouldn’t work. If you want to paste me your exact code, the one that doesn’t work, I can see if I can run it or if there’s some sort of problem that’s crept in …

  • Abhi September 14, 2014, 5:17 am

    Hi,John I have gone through your free videos which has helped to become a good programmer but John I need some of paid courses I can’t afford to pay the prices because don’t have credit card and here to credit card is one of the toughest job.
    So pls have a look to my request.
    Thank you

  • Ralph Hosmer September 12, 2014, 3:27 pm

    [copied from Udemy’ [posted 6 days ago]

    Lecture Comments

    I have some programming background (Basic, Visual Basic in msOffice, several AI languages: All mostly for personal gradification ).

    I’m thru Lecture 51 with working Eclipse programs and the Eclipse programs and output copy/pasted to an Excel Worksheet (for future off-line reference). As I’ve gone thru each Lecture, I’ve added COMMENTS to each program which hopefully represents the jist of your verbal lectures. QUESTION: Is there a TRANSCRIPT of your Lectures available ? Thank you for an excellent intro to JAVA. ps: The “screen capture” approach to the videos seems to result in slightly blury results – Still legible, but with some difficulity.

    • John September 12, 2014, 3:30 pm

      Hello Ralph, there is no transcript, but on Udemy I believe it’s possible to switch on captions, which seem to be excellent. Be sure to switch on HD too — otherwise the video will definitely be blurry. There should be a HD button somewhere around the lower right when the video plays.

      • Ralph Hosmer September 12, 2014, 4:37 pm

        Thank you John,
        I kept cleaning my glasses, but it didn’t help my 75 year old eyes.

        • John September 12, 2014, 6:29 pm

          It should be fairly sharp with HD! Similar to a computer screen. My Eclipse default font is quite small though. I recently worked out how to change it … Good to have a reminder!

  • ibrahim September 8, 2014, 11:45 am

    your work is amazing :)
    i got ? that in your GUI course at Lesson 7 Communication Between Components you have change sysout by TextPanel.append(“..”);
    it show me error underlined in TextPanel that i cant append?

    • John September 11, 2014, 9:41 am

      Thanks! You need to use the object you created with “new”, not the class. E.g. myTextPanel.append() rather than TextPanel.append()

      • John September 11, 2014, 9:42 am

        I’ve just realised, you may have called your text panel object “TextPanel”. This isn’t a good idea — it should start with a lower-case letter; there may already be a class called TextPanel, which is causing the confusion.

  • Steve Kohler September 7, 2014, 4:06 pm

    I have been programming a long time, but somehow just procrastinated on Java. Thanks for putting your great course online and letting those of us who have let our skills lapse get caught back up without spending my family’s rent money! Keep it up. I am sure I will in fact be buying your more advanced courses.

    Steve Kohler

  • Edward August 31, 2014, 3:39 am

    Hi John,

    I bought all of your courses on Udemy (Spring, Servlets, Swing, Android and Perl). Do I need to purchase the courses again on your site?

    P.S. Your courses are awesome. It helped me understand the Object-Oriented and Design Pattern concepts using Java Programming Language.

    • John August 31, 2014, 8:29 am

      Thanks a lot Edward! If you register free on my site and let me know the email address you registered with, I’ll subscribe you to everything.

  • Keith August 29, 2014, 4:37 pm

    Hi there.

    Done with Java for Beginners and will probably do Collections and Threads next

    I googled for some sample java exercises with worked solutions and found a couple of decent sites, wondering if you have so e favourites you would recommend so I can practise the stuff you taught in Java for Beginners?

    Besides Collections, Threads and perhaps Design patterns, what else would you recommend?

    • John August 29, 2014, 9:34 pm

      Hi Keith, I don’t ever do exercises myself — only Googling for tutorials. But someone mentioned http://codingbat.com/ . Collections are really important to know about, so I can recommend that! You need at least the first few videos’ content to be able to do any real Java programming. After that you’re pretty much set to tackle whatever you want. Threads are vital for some programs, but not used at all in many.

  • Muhammad August 29, 2014, 11:23 am

    Hey John,
    I’m trying to create a chat application for android, I’m now trying to connect my app to mysql workbench database (for test). I’ve followed this tutorial
    Note : i tried to access localhost from android emulator using and my pc’s ip:8080 and localhost:8080 but i get HTTP Status 404, The requested resource is not available..
    Thanks :)

    • John August 29, 2014, 11:35 am

      I’m only familiar with JSON, so probably can’t help … I should think you can’t connect directly to your database in Android, only through a web service or JSON or something similar.

  • ahmed August 28, 2014, 8:05 pm

    when I open offres-servlet.xml
    i can’t see mvc button
    note: i have jar spring web-mvc download to the project

    • John August 28, 2014, 9:15 pm

      MVC button?

      • ahmed August 29, 2014, 3:32 pm

        hi John,
        i have eclipse
        Version: Luna Release (4.4.0)
        Build id: 20140612-0600
        on dependendcies tab i see mvc jar 1.6 and less.. but on your tutorial i see mvc jar 3.2.3 release .. how i get the latest jars

        • John August 29, 2014, 9:38 pm

          Are you looking at my Spring tutorial, Ahmed? If so, make sure your Maven repository is up to date (there is a FAQ showing how to update it attached to one of the final lectures, if you scrolled down the course list — titled “FAQ”), but most likely you are looking at the wrong dependency group ID. Make sure you go to the right bunch of Spring dependencies — the org.springframework ones if I remember rightly.

  • Ansul August 19, 2014, 11:37 am

    Hi John,

    I am really enjoying your beginner Java tutorial. I wanted to know, is there a website or something from where I can get programs/questions/problems to practice, to enhance my skills.


  • Baris Bozkurt August 18, 2014, 8:56 am

    Dear John,
    I have been watching your Java for beginners lectures for the last few days. I have already completed a few other similar online courses to compare teaching styles. Congratulations and thanks a lot for producing these great teaching materials and making them available. They are very clear, well-organised, and they present the core material in a very easy to understand style. They will for sure be inspirational to many people teaching similar content. My best regards.

  • Ki August 13, 2014, 2:08 pm

    Hi John, i am from China. Thanks for your efforts. I am following your Java beginners tutorial now. It makes points clear and simple.

    And I am wondering which fonts are you using in your eclipse because I can’t find it.

    • John August 13, 2014, 10:06 pm

      Hi Ki, I don’t know … can you post the code you are using? I don’t use any special font, just the default.

      • Ki August 14, 2014, 2:09 am

        Hi sir, I’m afraid the code will transform to default font when I post here. Never mind. My current font is OK.

        Thanks anyway. have a nice day.

  • Evert Dhont August 13, 2014, 6:03 am

    Hi there John!
    First of all, I like your work very much! Right now I am learning your Java for complete beginners course, and there I was playing with the code of the getting user input video and I wondered why if I enter some text in the program with a capital letter in it, the program just displays the first letter? I really don’t know what the problem is but it’s a kind of frustrating so I hope you can help me out!
    Thanks in advance,

    • John August 14, 2014, 11:57 am

      Post your code, Evert!

      • Evert August 14, 2014, 12:35 pm

        Thanks for help but it seems like I fixed the problem on my own… I think it had something to do with the version of Java I was using because I was programming on my android device… Now that I have my computer back, the problem isn’t there any more…

  • Arpan Sharma August 12, 2014, 2:38 pm

    Sir I have watched your free courses and i want to enroll for jsp & servlets but I don’t have any credit card.
    So what to do???

  • Justin Willingham August 8, 2014, 10:33 pm

    Thank you for doing this John. I completed your Java for Beginners course and I’m about half way through your Java Multi – threading course. Now preparing for my Oracle Associate Certification!!
    Thanks to your course… It’s really appreciated.

  • berker August 8, 2014, 7:06 pm

    hello John,

    i have been following your Java for Beginners tutorials from udemy.com for a couple of days now. They are quite good actually but i want to make a little suggestion.
    i searched google for Java exercises, both to practice and understand how different methods are used and found this http://www.ntu.edu.sg/home/ehchua/programming/java/J2a_BasicsExercises.html

    it was great to practice what i learned from your lessons, so i understand everything better but those exercises and your lessons does not sync. so it would be great if you can also supply some exercises with solutions for each lesson or maybe exercises for a group of lessons.

    by the way, i really appreciate what you have been doing here.


  • Muhammad August 6, 2014, 9:33 pm

    Hey John,
    I’m trying to connect my swing app to an online database as i can edit the database from other computers.. I need a website that host my database for free (as it’s a small app for test) and if I find that site how can I write the connect method ? I mean Class.forName(“what will be here ?”).newInstance();
    String connectionUrl = “and here ?”;
    Thanks. :)

    • John August 7, 2014, 12:52 pm

      The class.forName bit would be the same as if it’s on your local machine. The connection URL would depend on the URL where you’re connecting to your database. Your host will hopefully give you that information! Something like jdbc:mysql://localhost:3306/dbname, but localhost:3306 will be replaced by the URL or IP address and port number of your database, and dbname with the name of the database you create.

  • Onur August 6, 2014, 7:32 am

    Just wanted to thank you for your effort. I wonder if there is any way to follow the tutorial “offline” like a movie or something?


    • John August 6, 2014, 4:25 pm

      Hello Onur, it should be possible to download my videos one-by-one. If there are any you want to download and can’t, let me know, because maybe I just need to switch them to downloadable by hand. You can also find my courses on Udemy.com, where they should also all be downloadable.

  • vicky August 5, 2014, 6:38 am

    Hi, John

    I wanted JDBC tutorial from you. I dont know it’s already there or not please help me out.

    • John August 5, 2014, 11:34 am

      Hi Vicky, I include some basic JDBC stuff in several of my tutorials; especially the Swing one. But I don’t have a specific tutorial on it.

  • Emre Yavuz August 3, 2014, 12:03 pm

    Hello, I have learned a lot of your java turtorials but i got a question.

    Can you please make a turtorial about javaFX?

    I have heard Oracle is gonna focus more on javaFX than Swing

    I hope you do it :)

    with kind regards, Emre

    • John August 6, 2014, 4:58 pm

      I’ve made a few, so far … have a look at the video section …

  • speed August 2, 2014, 1:27 am

    hello john

    i want a subtitles for ur videos plz

    Java Swing (GUI) Programming: From Beginner to Expert


  • James McGiveran August 1, 2014, 5:35 am

    Hi John,

    I just wanted to thank you for all of your hard work. I am working my way through the Java for Complete Beginners and I find you to be one of the finest instructors, in any discipline, that I have ever encountered. Your explanations are clear and to the point. The shorter video format allows me to go back and forth and fiddle with the code. I am truly appreciative. Can you please recommend which course I should take next after this one? Are your courses set up beginner / intermediate / advanced or are they more subject based? Thanks again John, Jimmy

    • John August 1, 2014, 8:39 pm

      Thanks James! You can try any other of my courses after the beginners’ Java one really. Except it’s probably easier to tackle Servlets and JSPs before you do the Spring course.

  • sujay July 31, 2014, 8:20 pm

    John ,I am Sujay from India I have watched your tutorial for Java for complete beginners,this tutorials helped me lot in my exam.I wanted to buy your tutorials for java swing but now they are showing me 39$ ,which i can’t afford can you please tell me how to avail the discount for someone from india so that i can buy them for my next exam!
    Thanks in advance :)

  • Miguel Rios July 31, 2014, 6:17 pm

    Hi John! Thank you very much for your work!

  • Joseph July 31, 2014, 4:53 am

    Hello John.

    Just wanted to leave a comment to show gratitude. I am working my way through your java for beginners series and out of all the other tutorials that I have looked at I find yours to explain everything in a way that someone new to programming can understand. I plane to look at your other tutorials (focusing on java for now) and when the time comes I will have no problem purchasing the additional content. Please keep it up.

    Thank you

  • Kushal July 25, 2014, 2:33 pm

    Hi John,
    I love your work and appreciate your effort.
    Keep up the good work