Practice with language syntaxThese are the very first Java programming tasks for beginners — the foundation — from "Hello, World" to loops and arrays. CodeGym has lots of them: they are especially concentrated in the first six levels of the Java Syntax quest. You're unlikely to need to look for more of them elsewhere. We certainly have enough to master them. What's more, when you any more difficult task, you automatically review the syntax. But if you suddenly find yourself in need, any Java textbook for beginners contains similar problems. But unlike CodeGym, these exercise books won't have instant task verification.
Practice with collectionsCollections are the first "serious" topic that newbie programmers encounter in their studies. Beginner tasks devoted to Java collections are also well represented on CodeGym — on the seventh and eighth levels of the Java Syntax quest. This is where the student will first hear about the Java Collections Framework, and will work a little with the Set, List, and Map interfaces along with some of their implementations. However, at this stage you'll get only an introduction to this useful tool and simple Java tasks. You'll study collections more thoroughly during the Java Collections quest. You can see how important this subject is — an entire quest has been named after it!
Practice with exceptionsJava provides a special mechanism for handling exceptional situations, significantly simplifying the process of "catching" application errors. But to make the most of it, you need to figure out how exception handling works in Java. CodeGym has heaps of such tasks. You'll even encounter them in the first quest — Java Syntax.
Practice with type castingThis group of tasks could, of course, be classified as basic tasks on syntax. However, in our humble opinion, people often under-appreciate such tasks, and newbies flounder in them. That's why we break the mold: We don't study primitive type conversion tasks at the very beginning as others often do. Instead, we tackle them a little later — at the end of the Java Syntax quest. And then we'll learn to cast non-primitive types (objects) when we study OOP in the Java Core quest. CodeGym has enough of these tasks. You don't need to look any further.
Practice with OOPOOP is not the most difficult topic, but it's extremely important. And it hides a lot of subtleties that interviewers like to use to catch would-be junior developers. The CodeGym course contains practical programming tasks for beginners to help you understand the object-oriented philosophy. But to really understand OOP, we recommend that you read related literature (for example, Cay Horstmann's and Gary Cornell's "Core Java", McLaughlin's "Object-Oriented Analysis and Design", or other books).
Practice with input/output streamsWe start using I/O streams long before we understand them. This is Java, my young grasshopper! Explaining System.out, let alone System.in, is difficult and unnecessary when you first begin. But as you work through the Java Core quest, you know just enough to understand this somewhat confusing topic, and we talk about not only console I/O, but also working with the file system. The main thing is to not skip these tasks (CodeGym has quite a lot) and to consistently delve into the theory.
BrainteasersBy "brainteasers", we mean tasks of increased complexity that aren't so much about knowledge as about the ability to apply what you know in unconventional ways. These are common tasks for a junior Java developer. Companies are very fond of asking them during interviews, but in real work, such brainteasers are not encountered very often. So CodeGym has some, but not very many (you'll usually see these in lessons by Captain Squirrels). Where can I find brainteasers?
Algorithms and data structuresAs for algorithms and data structures, there's constant debate about how much a future programmer needs them. We'll answer once again: they are essential for establishing the right mindset, but they are rarely directly required for work. This is because Java, as well as other programming languages, have libraries with implementations of every imaginable algorithm for sorting, searching, and more. Still, writing your own implementation of an algorithm can be very helpful and can give you an idea of its complexity. Especially for people who studied math only in high school. Basically, these tasks can be interchanged with brainteasers with the sole difference that they have all been described and solved repeatedly online. You don't even need a validator tool. Choose any course from, say, Princeton University or a college in California. Practice with data structures:
MultithreadingAnyone can write a "Hello, World!" program. But how about using the Java Thread API to display the famous phrase from a separate thread? Or how about displaying "Hello, World!" five times from five different threads without mixing up the strings? Multithreading will be the best "test of your strength" as you study Java Core. An entire CodeGym quest, called Java Multithreading, is dedicated to this topic, which is far from easy. It contains a huge number of tasks to allow students to feel the "pain and beauty" of parallel processing. Students' first "real" projects usually contain some level of multithreading. For example, simple games.
Practice with multithreading
Five silent philosophers sit at a round table. A plate of spaghetti is in front of each of them. There are forks on the table between each philosopher (one to the left and one to the right). Each philosopher can either eat or think deep thoughts. But he or she can eat only if holding two forks, i.e. by picking up the one on the left and the one on the right. "Pick up fork" and "put down fork" are distinct actions that are performed sequentially.
Practice with genericsGeneralization is the very essence of automation, so in some sense it is the essence of programming. Accordingly, we cannot ignore the topic of generics in Java. CodeGym has programming tasks involving generics (mainly in the Java Collections quest, starting at Level 5). Where can I find useful exercises and materials on generics?
- "Effective Java" by Bruce Eckel
Practice with design patternsAt some point (two-thirds of the way through the CodeGym course), beginner programmers must start looking at the rules for achieving good form in programming. We're talking about proper code formatting (simpler) and design patterns (more difficult). CodeGym has tasks for this. You'll need more and you can find them in "Head First Design Patterns" by Elisabeth Freeman and Kathy Sierra. Or you can think about how you could apply design patterns to previously solved tasks.
Unit testingAn important skill for any programmer, often mistakenly attributed solely to testers, is the ability to write unit tests for his or her own code. CodeGym has a few tasks related to unit tests, but you don't really need to bother searching for more. When you understand out how to write unit tests, make it a habit to cover your code (in own projects, in your studies) with them. This is much more helpful than performing checks with console output, a practice that usually afflicts student programmers. In addition, very often the first thing that new junior developers are tasked with at companies is to write unit tests for someone else's code.
Practice with regular expressionsThis is a simple topic that almost no beginners understand, because it is unfamiliar and they're lazy. It really is worthwhile to spend a few days studying the topic, get to the bottom of "regex", and gain an advantage over those who haven't done so. This is also helpful because regular expressions are nearly language-independent: if you learn them once, you'll be able to use them everywhere. CodeGym doesn't have any tasks dedicated to regular expressions, though some can be solved with their help. Here are additional resources for understanding this topic:
- regex101.com — a website where you can check regular expressions online
- Mike Fitzgerald's "Introducing Regular Expressions" — a concise and simple primer.