Java – Basics
If you have no programming experience yet, then the following free materials are recommended to pass:

‣ Iakiv Kramarenko's book: Intro to Software Development (with examples in HTML, CSS, JavaScript) OR Harvard's CS50 on
‣ any of java courses on edx OR Udemy (1, 2, 3) OR something simpler like

If you have experience in programming, but not with Java, then you can quickly get familiar with the language through:

‣ Fast intro to the language syntax: Learn X in Y minutes Where X=java
‣ Simple interactive tasks on the language syntax in the format of tests: Java Koans

In the remaining time, you can practice more and harden your skills using one of the following resources: Java Track

Also, it will be more convenient for you if you will save versions of your code for solving certain problems - using version control systems. I recommend using git and one of its most popular servers – Here's a free tutorial on the topic: Github - Hello World.