A Java course for everyone - accessible yet serious, to take you from absolute beginner to an early intermediate level
Let’s parse that.
Programming Drills (code-alongs, with source code included)
Talk to us!
Note: This class has hundreds of lines of source code, and hundreds of lines of comments - just download and open in your IDE!
We - the course instructors - start with introductions. We are a husband-wife team, studied at Stanford, and spent several years working in top tech companies, including Google, Flipkart and Microsoft.
Next, we talk about the target audience for this course: folks who are completely new to programming - liberal arts majors, accountants, lawyers, doctors - as well as engineers who have done some programming (maybe in Python, C# or C++) and are now looking to learn Java from 0 to 1.
By the end of this class, you will be able a fairly serious Java programmer, at an early intermediate level. You will understand object-oriented concepts, concurrency and threading, language features such as reflection, annotations and so on. You will also build a substantial UI app using Swing, and learn about the MVC paradigm.
We will be making a useful Java application in this drill using concept of files, classes, nested classes and comparator. The Java application will download daily stock data from a stock exchange website and output an excel file of top movers and heavily traded stocks.
As computers have become multi-core, and then as cloud computing has taken off, the importance of threading has increased substantially. This lecture is an introduction to the concept of threading which allows programmers to do different things simultaneously. We will also discuss the differences between processes and threads, old school concepts vs new school concepts in threads and some use-cases of threads.
We'll talk about a specific use case for threading where spinning off multiple threads can give us huge performance gains. Java support for threading is great even in its traditional form. New libraries however, make working with threads far easier.
We study threading the way it has traditionally been done in Java - the Runnable interface; extending the Thread class; join(), sleep() and thread interrupts.
Multi-threading involves concurrent execution of threads, and this gives rise to an entire range of potential issues: thread interference, memory consistency and thread contention.
Methods can be marked as synchronized - we study the nuances of doing so. We also examine threading issues such as livelock, deadlock and starvation.
Let's figure out how to set up a multi-threaded program - and while doing so, we also encounter our first synchronization bug. We congratulate ourselves - wrestling with synchronization bugs is the badge of a serious programmer!
We continue with our drill, and use our first lock. We learn yet another important thread-related lesson - that static variables can not be locked using the synchronized keyword.
In this lecture, we will talk about new features of Java which significantly improves its support for concurrency - the Callable interface,executors,thread pools, lock objects, concurrent collections and atomic variables. We will show how these new features make multi-threading a lot more robust.
We go back and reprise our threading drill, but this time we do so using the new threading framework - Callables instead of Runnables, and Executors instead of the Thread objects, and Future objects to retrieve the results.
We now delve into the power of the new threading features - a CompletionService, for instance, which allows us to retrieve results from threads in the order in which they complete.
A coding drill that illustrates the appeal of lambda functions and aggregate operators. We will sort a list of names in the drill using two approaches - imperative and functional. We will use .stream() and aggregate functions.
Recursive functions are functions that call themselves. This can be a little abstract to wrap your head around, but once you do, the idea is - beautiful.
Frameworks are complicated sets of interconnected classes: they are incredibly powerful, but take some getting used to. This class introduces the concept of frameworks and explains how they work with a simple analogy. Using a framework has some trade offs, we give up complete control over our application in return for incredible speed of development and lots of built-in support.
Frameworks are heavily influenced by the Observer design pattern, communication is via events and the corresponding listeners.
This lesson explores the different classes that Swing provides for UI components such as menus (JMenuBar, JMenu, JMenuItem). Trees in Swing are pretty powerful but complicated to use, we learn how to deal with their intricacies.
We also learn how to capture and handle mouse events.
We build a serious Swing application - the News Curation App: The objective of the drill is to build an application that helps in curating news snippets and quickly summarizing articles. We will use helper classes to write to an HTML file, set up the Model portion of the MVC paradigm. This stores the underlying data for the application.
Loonycorn is us, Janani Ravi, Vitthal Srinivasan, Swetha Kolalapudi and Navdeep Singh. Between the four of us, we have studied at Stanford, IIM Ahmedabad, the IITs and have spent years (decades, actually) working in tech, in the Bay Area, New York, Singapore and Bangalore.
Janani: 7 years at Google (New York, Singapore); Studied at Stanford; also worked at Flipkart and Microsoft
Vitthal: Also Google (Singapore) and studied at Stanford; Flipkart, Credit Suisse and INSEAD too
Swetha: Early Flipkart employee, IIM Ahmedabad and IIT Madras alum
Navdeep: longtime Flipkart employee too, and IIT Guwahati alum
We think we might have hit upon a neat way of teaching complicated tech courses in a funny, practical, engaging way, which is why we are so excited to be here on Udemy!
We hope you will try our offerings, and think you'll like them :-)