mirror of
https://github.com/Zormm/Advent-Of-Code-2022.git
synced 2026-02-26 07:26:51 +01:00
.
This commit is contained in:
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"java.project.sourcePaths": ["src"],
|
||||
"java.project.outputPath": "bin",
|
||||
"java.project.referencedLibraries": [
|
||||
"lib/**/*.jar"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
## Getting Started
|
||||
|
||||
Welcome to the VS Code Java world. Here is a guideline to help you get started to write Java code in Visual Studio Code.
|
||||
|
||||
## Folder Structure
|
||||
|
||||
The workspace contains two folders by default, where:
|
||||
|
||||
- `src`: the folder to maintain sources
|
||||
- `lib`: the folder to maintain dependencies
|
||||
|
||||
Meanwhile, the compiled output files will be generated in the `bin` folder by default.
|
||||
|
||||
> If you want to customize the folder structure, open `.vscode/settings.json` and update the related settings there.
|
||||
|
||||
## Dependency Management
|
||||
|
||||
The `JAVA PROJECTS` view allows you to manage your dependencies. More details can be found [here](https://github.com/microsoft/vscode-java-dependency#manage-dependencies).
|
||||
@@ -0,0 +1,27 @@
|
||||
import java.io.IOException;
|
||||
import java.io.RandomAccessFile;
|
||||
|
||||
public class main {
|
||||
public static void main(String[] args) throws IOException {
|
||||
RandomAccessFile file = new RandomAccessFile("input.txt", "r");
|
||||
String str;
|
||||
|
||||
//Part 1
|
||||
System.out.print("Part 1: ");
|
||||
|
||||
while ((str = file.readLine()) != null) {
|
||||
System.out.println(str);
|
||||
int blueprintID = Integer.typeOf(str.substring(11,12));
|
||||
int costOfOreRobot = str.subString();
|
||||
simulateRobotWithBlueprints();
|
||||
}
|
||||
//Part 2
|
||||
System.out.print("Part 2: ");
|
||||
}
|
||||
|
||||
public int simulateRobotWithBlueprints(int costOfOreRobot, int costOfClayRobot, int costOfObsidianRobot, int costOfGeodeRobot, int timeInMinutes) {
|
||||
int maximumNumberOfOpenedGeodes = 0;
|
||||
|
||||
return maximumNumberOfOpenedGeodes;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user