
This course includes our updated coding exercises so you can practice your skills as you learn.
See a demo
Learn Java programming from scratch through a hands-on, well-structured course for complete beginners, featuring more than 50 exercises and step-by-step guidance.
Java for newcomers reveals why learning programming matters, from weather forecasts and computing to automation and control in everyday devices, and presents Java as a business-friendly language for basics.
Learn Java by doing with a vehicle trade project that builds basics step by step, including 50+ tasks and detailed solutions.
Learn the essentials to start Java development using Java 21 from Eclipse Temurin and the IntelliJ IDEA community edition; install Java, IDEs, and course materials across operating systems.
Install IntelliJ IDEA Community Edition on Windows, download the proper architecture, and run the installer. Accept the license and optional data sharing, and pin IntelliJ to the taskbar.
Download the course materials on windows and open the JNewcomers project in IntelliJ, then configure your Java SDK and set up IdeaProjects for a seamless Java starter workspace.
Identify your macOS architecture (Apple Silicon or Intel), download Java 21 for that architecture from adoptium.net, and install the .pkg via the installer.
Install IntelliJ IDEA on macOS by downloading the community edition for your processor architecture, accept the license, and set the appearance to light to match the videos.
download course materials on macOS using IntelliJ IDEA Community Edition, set up a project in IdeaProjects, and trust project to begin introduction to programming with your first Java program.
Install Java on Linux by downloading Eclipse Temurin for x64 or aarch64, extracting the tar archive to /opt, and preparing for IntelliJ IDEA Community Edition.
Install IntelliJ IDEA on Linux by downloading the Community Edition, ensuring Java is installed from the previous lesson, extracting the tar archive to /opt, and launching ideas.sh.
Learn to use IntelliJ IDEA, distinguish graphical and console applications, read and write console input, run and debug Java programs, and apply control flow, variables, naming rules, and code formatting.
Explore the development environment in IntelliJ IDEA, navigate the project view and editor, and compare graphical user interfaces with console applications as you prepare to write your first Java program.
Create your first Java program in module 1000, VehicleTrade, by printing a welcome message with System.out.println to the console in IntelliJ. Run it with the play button.
Explore control flow in Java through two statements that print to the console, and see how source code and IntelliJ modules organize a program while navigating technical terms.
Create a console-based selection menu for a vehicle trade customer and print two extra lines of text to the console, practicing Java programming through guided tasks in module 1200.
Extend the program by adding two more System.out.printline statements to print four lines in sequence with the expected result. Embrace mistakes and practice finding and fixing errors.
Learn how Java syntax errors like missing semicolons and braces arise, and use IntelliJ tools, quick fixes, bracket matching, auto formatting, and file comparison to find and fix them.
Learn efficient code editing in Java from scratch by using copy and paste, duplicating lines with Ctrl D, and using IntelliJ sout live templates to create print statements.
Learn to read integer input from the console in Java with a scanner, declare and initialize a variable, and understand Java's type-safe data types.
Master naming variables in Java with conventions for uniqueness and readability. Start names with a lowercase letter, use camelCase, avoid keywords as names, respect case sensitivity, and choose meaningful nouns.
The lecture explains how a computer works, detailing the CPU fetching and decoding instructions, loading data from main memory, and storing results, with storage like hard disks or solid-state disks.
Format the source code around an if-statement to improve readability using spaces, tabs, and line breaks. Learn indenting with braces and blocks, and how IntelliJ's Ctrl Alt L formats code.
Enhance the selection menu logic to handle one or two options, inform users when no used vehicles are available, and guide beginners to repeat lessons for mastery.
Demonstrate adding a second if-statement to handle menu options, printing vehicle categories for one and a no-vehicles hint for two, and note nesting issues and IntelliJ debugger use for explanation.
Master using IntelliJ's debugger to visualize control flow, set breakpoints, and step through code, while inspecting variables and console input.
Learn foundational programming basics and essential technical terms as you take your first steps toward becoming a developer, with upcoming practical lessons on expressions and the else statement.
Explore arithmetic operators, the evaluation of expressions, floating point arithmetics, algorithms, and if else statements. The section is optional, but watch the else and conditional statements and lesson types.
Implement credit advice as a third menu option by asking for the vehicle price, adding a 20 handling charge, and printing the credit amount to the console.
Calculate the monthly payment by reading the financing period from the console, compute the credit amount including the handling charge, divide by months, and print the truncated result.
Read the number of monthly payments from the user and divide the credit amount by that number to compute the monthly payment; print the result.
Explore how the double data type preserves decimal places when calculating the monthly rate, and why integer division loses cents in the initial calculation.
Explore how to write a compound arithmetic expression in Java, control operator precedence with parentheses, and ensure floating point results by using double values, illustrated with credit calculations.
Apply basic Java arithmetic to compute interest on the vehicle price by multiplying it by 1.03. Explain operator precedence for multiplication, addition, and subtraction in the monthly payment calculation.
Explore algorithms by moving from concrete examples—distributing apples to horses—to an abstract framework that defines the problem of evenly distributing n pieces to m recipients, i.e., an algorithm.
Explore the modulo operator and how it returns the remainder of integer division. See 13 modulo 5 and use an if statement in Java to accept only multiples of 12.
Explore the course's lesson types, learning, task, exercise, and solution, each identified by a module letter. Learn how tasks relate to the vehicle trade and why star-marked solution lessons matter.
Begin a Java programming exercise that uses a scanner for console input to distribute apples among horses, calculating apples per horse and remaining apples from sample scenarios.
Explore solving a horse feeding exercise in Java by reading input, performing integer division and modulo operations, and printing apples per horse and remaining apples.
Master arithmetic operators, expression evaluation, algorithms, and floating point arithmetic, and grasp the if-else statement, as you prepare to tackle loops in the next section.
Learn how to use loops to execute code repeatedly, manage loop termination, and understand the scope of local variables. Also explore how to write pseudo code to plan Java programs.
Demonstrates the do-while loop in Java, showing how to repeat a menu until termination, explores endless versus finite loops, and explains termination conditions, control flow, and line comments.
Move the declaration of selection before the do-while loop to extend the variable's scope. Use the not equal operator to terminate the loop when the customer enters nine.
Practice reading pairs of integers from the console using a do-while loop in Java until their sum equals 42, with sum computed as x plus y.
Read two numbers from the console into x and y, compute their sum, and repeat until sum equals 42 using a do-while loop and IntelliJ surround-with feature.
Learn when and how to use pseudocode to plan solutions, and practice breaking problems into variables, loops, and if-statements before translating to Java.
Explore the while loop, a head controlled loop that checks the termination condition before the body, and compare it to the do-while loop's foot controlled behavior, including initialization.
Apply the while loop to replace the do-while approach in the sum of two numbers exercise, completing part two of three.
Replace the do-while with a while loop by moving the termination condition to the head, and initialize sum to zero in the sum of two numbers exercise.
Learn how the break statement terminates a loop independently of its condition, by wrapping break in an if that checks for the customer entering nine.
Master the break statement by modifying the sum of two numbers exercise to terminate the loop when 4711 is entered, completing part three of the Java for newcomers course.
Explore solution to sum of two numbers part three, using break to exit loop on 4711 and avoiding copy-paste errors by printing congratulations only if sum is 42.
Master loop control and local variable scope in Java by exploring do-while and while loops with termination and break, writing pseudocode, and preparing for the datatype to store text.
Learn how to store and compare text, ignore capitalization, and concatenate strings in Java for beginners.
Read a vehicle category from the console into a String and compare it to 'SportsCar' using equals. Use an if-else to handle no sports cars versus searching the requested category.
Learn to perform case-insensitive string comparison with equalsIgnoreCase and to concatenate strings with the plus operator, ensuring proper spacing and wrapping lines for readable code.
Master string concatenation in Java by building complete sentences with vehicle price and monthly payments, using the concat operator and proper punctuation to craft user prompts.
Master string concatenation in Java using the concat operator to build sentences, append punctuation, and format a payment message like 'Please pay' with numberOfMonthlyPayments and 'monthly payments of $'.
Master string operations in Java by storing, comparing, ignoring capitalization, and concatenating text, as you complete the string section and prepare for enhanced control flow and boolean logic.
Explore the else-if branch in if-statements, and master the logical or and logical and operators along with relational operators.
Explore how else-if branches extend if statements in Java, using vehicle categories to illustrate conditional blocks A–D, the order of branches, and handling unknown categories.
Inform customers that there are no used cabriolets on offer at the moment, in spring, as it is done for sports cars, using an else if approach.
Add an else-if branch for cabriolets, duplicating one and adjusting the condition to check for cabriolets, then adapt the if-block message to state no used cabriolets are on offer.
Explore using the logical or operator to merge vehicle category checks into one code block, with boolean expressions and proper brackets.
Apply the logical or operator to combine cabriolet and sports car conditions in an if-branch and print an appropriate message to the console.
Combine cabriolet and sports car categories in an if-branch using the or operator, and print a dynamic message with the requested vehicle category on offer via string concatenation.
Explore the logical and operator in Java, using two ampersands to combine boolean expressions; apply it to if statements, and learn that and has higher precedence than or.
Explore relational operators in Java, mastering less than, less than or equal to, greater than, and greater than or equal to when comparing values, with practical tasks.
Learn how to validate credit applications by enforcing that monthly payments are positive and a multiple of 12 using logical and relational operators in Java for newcomers.
Learn to validate credit applications by ensuring the monthly payments are positive and a multiple of 12. Apply the greater than operator and the logical and to require both conditions.
Master the else-if branch in if-statements, the logical or operator, the logical and operator, and relational operators.
Explore nested loops, the boolean data type, and the logical not operator, and examine variable scope inside loops to improve control flow in Java.
Learn nested loops and do-while constructs by analyzing a vehicle trader scenario, using inner and outer loops to repeat a menu until a vehicle category is available.
Learn how to use the boolean data type and true/false literals to control a loop, using a flag named vehicleCategoryAvailable to terminate when an available vehicle category is chosen.
Discover how the logical not operator negates a boolean value to simplify loop termination in Java, using the exclamation mark and parentheses for complex expressions.
Explore the control flow of nested do-while loops that repeatedly prompt a menu and a vehicle category, until a category on offer is chosen, while illustrating local variable scope.
Repeat until the sum of three numbers read from the console is 42 or less, using an inner loop and a loop counter, and celebrate when achieved.
Read three numbers from console, sum them with an inner loop, and repeat with a do-while and loop counter i until the sum is <= 42, resetting sum before pass.
Master nested loops, the boolean data type, and the logical not operator while learning about the scope of variables in loops; next, explore instance variables and their scope.
In the course "Java for newcomers" you will learn programming your computer in Java from scratch.
Java is an awesome programming language and is perfectly suited for learning the basics of programming.
In the business world, Java is one of the most frequently used programming languages.
This course is designed for complete beginners and is ideal for anyone who wants to learn programming.
If you already have programming experience, you might skip several exercises to make faster progress with
this course.
This course at a glance:
hands-on: learn to program by programming
50 programming exercises
designed by an experienced trainer for beginners
well-structured
everything is explained step by step, nothing is assumed
I hope you like this course and join us!
Your trainer:
My name is Torsten Krüger from jtrainer and I will guide you through this course.
I'm an experienced trainer for beginners and the excellent feedback from my classroom training
participants has inspired me to offer this online course.
A short summary of the feedback from my classroom training participants:
pleasant voice and speed when explaining
very clear, intuitive and visual explanations
small theory blocks and many practical exercises
good examples for all problems
didactically very good
well-structured
humor and professionalism
fantastic trainer
very competent
honestly interested in the success of all