problem 3 work

This commit is contained in:
Xevion
2019-09-19 09:17:15 -05:00
parent d3d823f6c3
commit ff1db0a8ab
12 changed files with 248 additions and 97 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
+17 -4
View File
@@ -2,6 +2,8 @@ import static java.lang.System.*;
import java.io.File; import java.io.File;
import java.io.FileNotFoundException; import java.io.FileNotFoundException;
import java.util.Arrays; import java.util.Arrays;
import java.util.List;
import java.util.ArrayList;
import java.util.Scanner; import java.util.Scanner;
class Point { class Point {
@@ -11,19 +13,30 @@ class Point {
this.x = x; this.x = x;
this.y = y; this.y = y;
} }
void merge(Point other) {
this.x += other.x;
this.y += other.y;
}
void merge(int x, int y) {
this.x += x;
this.y += y;
}
} }
class CheckerBoard { class CheckerBoard {
Point[] offsets = {Point(1, 1), Point(-1, -1), Point(-1, 1), Point(1, -1)}; List<Point> offsets = Arrays.asList(new Point[]{Point(1, 1), Point(-1, -1), Point(-1, 1), Point(1, -1)});
CheckerBoard(String[][] matrix) { CheckerBoard(String[][] matrix) {
} }
int[][] getPossible(int x, int y) { List<Point> getPossible(int x, int y) {
return getPossible(x, y, new int[0][0]); return getPossible(x, y, new ArrayList<Point>());
} }
int[][] getPossible(int x, int y, List<Point> blacklist) {}
List<Point> getPossible(int x, int y, List<Point> blacklist) {}
} }
class problem12 { class problem12 {
+6
View File
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/../../../.." vcs="Git" />
</component>
</project>
+128 -27
View File
@@ -1,7 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="250f6713-4389-436f-88a0-d6dffc72af7e" name="Default Changelist" comment="" /> <list default="true" id="250f6713-4389-436f-88a0-d6dffc72af7e" name="Default Changelist" comment="">
<change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../../12/bin/CheckerBoard.class" beforeDir="false" afterPath="$PROJECT_DIR$/../../12/bin/CheckerBoard.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../../12/bin/Point.class" beforeDir="false" afterPath="$PROJECT_DIR$/../../12/bin/Point.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../../12/bin/problem12.class" beforeDir="false" afterPath="$PROJECT_DIR$/../../12/bin/problem12.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../../12/src/problem12.java" beforeDir="false" afterPath="$PROJECT_DIR$/../../12/src/problem12.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/input.dat" beforeDir="false" afterPath="$PROJECT_DIR$/input.dat" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/problem3.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/problem3.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../../9/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/../../9/.idea/workspace.xml" afterDir="false" />
</list>
<ignored path="$PROJECT_DIR$/out/" /> <ignored path="$PROJECT_DIR$/out/" />
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" /> <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
@@ -38,16 +48,52 @@
</counts> </counts>
</usages-collector> </usages-collector>
</session> </session>
<session id="-1963689904">
<usages-collector id="statistics.lifecycle.project">
<counts>
<entry key="project.open.time.0" value="1" />
<entry key="project.opened" value="1" />
</counts>
</usages-collector>
<usages-collector id="statistics.file.extensions.edit">
<counts>
<entry key="dat" value="23" />
<entry key="java" value="2538" />
</counts>
</usages-collector>
<usages-collector id="statistics.file.types.edit">
<counts>
<entry key="JAVA" value="2538" />
<entry key="PLAIN_TEXT" value="23" />
</counts>
</usages-collector>
<usages-collector id="statistics.file.extensions.open">
<counts>
<entry key="dat" value="7" />
<entry key="java" value="2" />
</counts>
</usages-collector>
<usages-collector id="statistics.file.types.open">
<counts>
<entry key="JAVA" value="2" />
<entry key="PLAIN_TEXT" value="7" />
</counts>
</usages-collector>
</session>
</component> </component>
<component name="FileEditorManager"> <component name="FileEditorManager">
<leaf> <leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file pinned="false" current-in-tab="true"> <file pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/problem3.java"> <entry file="file://$PROJECT_DIR$/src/problem3.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="187"> <state relative-caret-position="216">
<caret line="11" column="15" selection-start-line="11" selection-start-column="15" selection-end-line="11" selection-end-column="15" /> <caret line="68" column="32" selection-start-line="68" selection-start-column="32" selection-end-line="68" selection-end-column="32" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#456#457#0" expanded="true" />
<element signature="e#517#518#0" expanded="true" />
<element signature="e#641#648#0" expanded="true" />
<element signature="e#692#699#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@@ -62,6 +108,14 @@
</list> </list>
</option> </option>
</component> </component>
<component name="FindInProjectRecents">
<findStrings>
<find>out.println</find>
</findStrings>
</component>
<component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$/../../../.." />
</component>
<component name="GradleLocalSettings"> <component name="GradleLocalSettings">
<option name="projectSyncType"> <option name="projectSyncType">
<map> <map>
@@ -74,6 +128,7 @@
<component name="IdeDocumentHistory"> <component name="IdeDocumentHistory">
<option name="CHANGED_PATHS"> <option name="CHANGED_PATHS">
<list> <list>
<option value="$PROJECT_DIR$/input.dat" />
<option value="$PROJECT_DIR$/src/problem3.java" /> <option value="$PROJECT_DIR$/src/problem3.java" />
</list> </list>
</option> </option>
@@ -84,28 +139,30 @@
<option name="width" value="974" /> <option name="width" value="974" />
<option name="height" value="1057" /> <option name="height" value="1057" />
</component> </component>
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
<component name="ProjectView"> <component name="ProjectView">
<navigator proportions="" version="1"> <navigator proportions="" version="1">
<foldersAlwaysOnTop value="true" /> <foldersAlwaysOnTop value="true" />
</navigator> </navigator>
<panes> <panes>
<pane id="Scope" />
<pane id="PackagesPane" />
<pane id="ProjectPane"> <pane id="ProjectPane">
<subPane> <subPane>
<expand> <expand>
<path> <path>
<item name="3" type="b2602c69:ProjectViewProjectNode" /> <item name="java" type="b2602c69:ProjectViewProjectNode" />
<item name="3" type="462c0819:PsiDirectoryNode" /> <item name="java" type="462c0819:PsiDirectoryNode" />
</path> </path>
</expand> </expand>
<select /> <select />
</subPane> </subPane>
</pane> </pane>
<pane id="Scope" />
<pane id="PackagesPane" />
</panes> </panes>
</component> </component>
<component name="PropertiesComponent"> <component name="PropertiesComponent">
<property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568536537998" /> <property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568902382723" />
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
<property name="settings.editor.selected.configurable" value="preferences.pluginManager" /> <property name="settings.editor.selected.configurable" value="preferences.pluginManager" />
</component> </component>
<component name="RunDashboard"> <component name="RunDashboard">
@@ -120,6 +177,20 @@
</list> </list>
</option> </option>
</component> </component>
<component name="RunManager">
<configuration name="problem3" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true">
<option name="MAIN_CLASS_NAME" value="problem3" />
<module name="3" />
<method v="2">
<option name="Make" enabled="true" />
</method>
</configuration>
<recent_temporary>
<list>
<item itemvalue="Application.problem3" />
</list>
</recent_temporary>
</component>
<component name="SvnConfiguration"> <component name="SvnConfiguration">
<configuration /> <configuration />
</component> </component>
@@ -137,43 +208,73 @@
<frame x="-8" y="-8" width="1936" height="1066" extended-state="6" /> <frame x="-8" y="-8" width="1936" height="1066" extended-state="6" />
<editor active="true" /> <editor active="true" />
<layout> <layout>
<window_info id="Image Layers" /> <window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.25266525" />
<window_info id="Designer" />
<window_info id="UI Designer" />
<window_info id="Capture Tool" />
<window_info id="Favorites" side_tool="true" />
<window_info active="true" content_ui="combo" id="Project" order="0" visible="true" weight="0.25" />
<window_info id="Structure" order="1" side_tool="true" weight="0.25" /> <window_info id="Structure" order="1" side_tool="true" weight="0.25" />
<window_info anchor="bottom" id="Version Control" show_stripe_button="false" /> <window_info id="Image Layers" order="2" />
<window_info anchor="bottom" id="Terminal" /> <window_info id="Designer" order="3" />
<window_info anchor="bottom" id="Event Log" side_tool="true" /> <window_info id="UI Designer" order="4" />
<window_info id="Capture Tool" order="5" />
<window_info id="Favorites" order="6" side_tool="true" />
<window_info anchor="bottom" id="Messages" weight="0.32939914" />
<window_info anchor="bottom" id="Message" order="0" /> <window_info anchor="bottom" id="Message" order="0" />
<window_info anchor="bottom" id="Find" order="1" /> <window_info anchor="bottom" id="Find" order="1" />
<window_info anchor="bottom" id="Run" order="2" /> <window_info active="true" anchor="bottom" id="Run" order="2" visible="true" weight="0.35193133" />
<window_info anchor="bottom" id="Debug" order="3" weight="0.4" /> <window_info anchor="bottom" id="Debug" order="3" weight="0.39914164" />
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" /> <window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" /> <window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
<window_info anchor="bottom" id="TODO" order="6" /> <window_info anchor="bottom" id="TODO" order="6" />
<window_info anchor="right" id="Palette" /> <window_info anchor="bottom" id="Terminal" order="7" />
<window_info anchor="right" id="Theme Preview" /> <window_info anchor="bottom" id="Event Log" order="8" side_tool="true" />
<window_info anchor="right" id="Capture Analysis" /> <window_info anchor="bottom" id="Version Control" order="9" show_stripe_button="false" />
<window_info anchor="right" id="Palette&#9;" />
<window_info anchor="right" id="Maven Projects" />
<window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" /> <window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
<window_info anchor="right" id="Ant Build" order="1" weight="0.25" /> <window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" /> <window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
<window_info anchor="right" id="Palette" order="3" />
<window_info anchor="right" id="Capture Analysis" order="4" />
<window_info anchor="right" id="Theme Preview" order="5" />
<window_info anchor="right" id="Palette&#9;" order="6" />
<window_info anchor="right" id="Maven Projects" order="7" />
</layout> </layout>
</component> </component>
<component name="VcsContentAnnotationSettings"> <component name="VcsContentAnnotationSettings">
<option name="myLimit" value="2678400000" /> <option name="myLimit" value="2678400000" />
</component> </component>
<component name="editorHistoryManager"> <component name="editorHistoryManager">
<entry file="jar://C:/Program Files/AdoptOpenJDK/jdk-8.0.212.04-hotspot/src.zip!/java/lang/Object.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="436">
<caret line="234" column="18" selection-start-line="234" selection-start-column="18" selection-end-line="234" selection-end-column="18" />
<folding>
<element signature="e#11062#11063#0" expanded="true" />
<element signature="e#11145#11146#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="jar://C:/Program Files/AdoptOpenJDK/jdk-8.0.212.04-hotspot/src.zip!/java/lang/String.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="232">
<caret line="657" selection-start-line="657" selection-end-line="657" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/input.dat">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="238">
<caret line="14" column="17" lean-forward="true" selection-start-line="14" selection-start-column="17" selection-end-line="14" selection-end-column="17" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/problem3.java"> <entry file="file://$PROJECT_DIR$/src/problem3.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="187"> <state relative-caret-position="216">
<caret line="11" column="15" selection-start-line="11" selection-start-column="15" selection-end-line="11" selection-end-column="15" /> <caret line="68" column="32" selection-start-line="68" selection-start-column="32" selection-end-line="68" selection-end-column="32" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#456#457#0" expanded="true" />
<element signature="e#517#518#0" expanded="true" />
<element signature="e#641#648#0" expanded="true" />
<element signature="e#692#699#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
+2 -2
View File
@@ -12,8 +12,8 @@
F F
F F |
4
UUUUULL UUUUULL
UULULUL UULULUL
UUUUUURUULL UUUUUURUULL
Binary file not shown.
Binary file not shown.
+66 -25
View File
@@ -1,39 +1,50 @@
import static java.lang.System.*; import static java.lang.System.*;
import java.io.File; import java.io.File;
import java.io.FileNotFoundException; import java.io.FileNotFoundException;
import java.util.Scanner;
import java.util.Set; import java.util.Set;
import java.util.Arrays;
import java.util.List;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Scanner;
import java.util.HashSet;
class Point { class Point {
int x; int x, y;
int y;
Point(int x, int y) { Point(int x, int y) {
this.x = x; this.x = x;
this.y = y; this.y = y;
} }
void merge(Point other) {
this.x += other.x;
this.y += other.y;
}
public String toString() {
return String.format("Point(%d, %d)", this.x, this.y);
}
} }
class Maze { class Maze {
int[][] offsets = {{0, 1}, {1, 0}, {0, -1}, {-1, 0}}; // Offset Constants
String[][] rawMatrix; List<Point> positionOffsets = Arrays.asList(new Point(0, 1), new Point(1, 0), new Point(0, -1), new Point(-1, 0));
Set<Point> snake; List<String> nameOffsets = Arrays.asList("U R D L".split(" "));
Set<Point> pellets; // Maze Data
private List<Point> snake = new ArrayList<Point>();;
private List<Point> pellets = new ArrayList<Point>();
private char[][] rawMatrix;
Maze(String[][] rawMatrix) { Maze(char[][] rawMatrix) {
this.rawMatrix = rawMatrix; this.rawMatrix = rawMatrix;
snake = new ArrayList<Point>();
for(int x = 0; x < 15; x++) { for(int x = 0; x < 15; x++) {
for(int y = 0; y < 15; y++) { for(int y = 0; y < 15; y++) {
switch(rawMatrix[x][y]) { switch(rawMatrix[x][y]) {
case " ": case ' ':
break; break;
case "X": case 'X':
snake.add(new Point(x, y)); this.snake.add(new Point(x, y));
break; break;
case "F": case 'F':
pellets.add(new Point(x, y)); this.pellets.add(new Point(x, y));
break; break;
default: default:
out.println("Possibly faulty Maze Input with item \"" + rawMatrix[x][y] + "\" found."); out.println("Possibly faulty Maze Input with item \"" + rawMatrix[x][y] + "\" found.");
@@ -45,20 +56,42 @@ class Maze {
// Simulate the snake game using instructions // Simulate the snake game using instructions
String simulate(String input) { String simulate(String input) {
return ""; char curDirection = 'R';
int score = 0;
for(int i = 0; i < input.length(); i++) {
// Calculate the offset based on the current instruction
Point offset;
char curOffset = input.charAt(i);
if(curOffset == 'O')
offset = positionOffsets.get(nameOffsets.indexOf(curDirection));
else
offset = positionOffsets.get(nameOffsets.indexOf(input.substring(i, i+1)));
out.println(offset);
// Calculate the new point, ensure it's real
Point newPoint = snake.get(snake.size() -1);
newPoint.merge(offset);
if(!this.inBounds(newPoint))
return "GAME OVER @ " + newPoint;
// Add new point, discard end of snake to simulate it's movement
snake.add(newPoint);
snake.remove(0);
// Check if we're at a pellet
score += pellets.contains(newPoint) ? 1 : 0;
}
return Integer.toString(score);
} }
boolean inBounds(int x, int y) { // Methods for testing whether a position is in the maze's boundaries
return x >= 0 && y >= 0 && x < 15 && y < 15; public boolean inBounds(Point point) {return this.inBounds(point.x, point.y);}
} private boolean inBounds(int x, int y) {return x >= 0 && y >= 0 && x < 15 && y < 15;}
// Prints a string representation of the Maze // Prints a string representation of the Maze
String toString() { public String toString() {
String[] lines = new String[15]; String[] lines = new String[15];
for(int x = 0; x < 15; x++) { for(int x = 0; x < 15; x++) {
String[] temp = ""; String[] temp = new String[15];
for(int y = 0; y < 15; y++) { for(int y = 0; y < 15; y++) {
temp[y] = rawMatrix[x][y]; temp[y] = Character.toString(rawMatrix[x][y]);
} }
lines[x] = String.join(" - ", temp); lines[x] = String.join(" - ", temp);
} }
@@ -69,23 +102,31 @@ class Maze {
public class problem3 { public class problem3 {
public static void main(String[] args ) throws FileNotFoundException { public static void main(String[] args ) throws FileNotFoundException {
// Constants // Constants
File input = new File("input.dat"); File fileInput = new File("input.dat");
Scanner read = new Scanner(input); Scanner read = new Scanner(fileInput);
// Read the maze into a String matrix // Read the maze into a String matrix
char[][] rawMatrix = new String[15][15]; char[][] rawMatrix = new char[15][15];
for(int x = 0; x < 15; x++) { for(int x = 0; x < 15; x++) {
String line = read.nextLine(); String line = read.nextLine();
for(int y = 0; y < 15; y++) { for(int y = 0; y < 15; y++) {
rawMatrix[x][y] = line.charAt(y); rawMatrix[x][y] = line.charAt(y);
} }
} }
Maze originalMaze = new Maze(rawMatrix);
// Read each of the inputs and process inside the maze // Read each of the inputs
int lines = Integer.parseInt(read.nextLine()); int lines = Integer.parseInt(read.nextLine());
String[] inputs = new String[lines]; String[] inputs = new String[lines];
for(int i = 0; i < lines; i++) for(int i = 0; i < lines; i++)
inputs[i] = read.nextLine(); inputs[i] = read.nextLine();
// Simulate inputs
for(String input : inputs) {
Maze temp = originalMaze;
out.println(temp.simulate(input));
out.println(temp);
}
} }
} }
+29 -39
View File
@@ -2,10 +2,11 @@
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="814c54e4-1bbe-4be8-8fee-dff98faded8f" name="Default Changelist" comment=""> <list default="true" id="814c54e4-1bbe-4be8-8fee-dff98faded8f" name="Default Changelist" comment="">
<change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" /> <change beforePath="$PROJECT_DIR$/../12/bin/CheckerBoard.class" beforeDir="false" afterPath="$PROJECT_DIR$/../12/bin/CheckerBoard.class" afterDir="false" />
<change afterPath="$PROJECT_DIR$/input.dat" afterDir="false" /> <change beforePath="$PROJECT_DIR$/../12/bin/Point.class" beforeDir="false" afterPath="$PROJECT_DIR$/../12/bin/Point.class" afterDir="false" />
<change afterPath="$PROJECT_DIR$/src/problem9.java" afterDir="false" /> <change beforePath="$PROJECT_DIR$/../12/bin/problem12.class" beforeDir="false" afterPath="$PROJECT_DIR$/../12/bin/problem12.class" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../8/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/../8/.idea/workspace.xml" afterDir="false" /> <change beforePath="$PROJECT_DIR$/../12/src/problem12.java" beforeDir="false" afterPath="$PROJECT_DIR$/../12/src/problem12.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
</list> </list>
<ignored path="$PROJECT_DIR$/out/" /> <ignored path="$PROJECT_DIR$/out/" />
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" /> <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
@@ -18,9 +19,10 @@
<session id="-929831496"> <session id="-929831496">
<usages-collector id="statistics.lifecycle.project"> <usages-collector id="statistics.lifecycle.project">
<counts> <counts>
<entry key="project.closed" value="1" /> <entry key="project.closed" value="2" />
<entry key="project.open.time.1" value="1" /> <entry key="project.open.time.1" value="1" />
<entry key="project.opened" value="1" /> <entry key="project.open.time.4" value="1" />
<entry key="project.opened" value="2" />
</counts> </counts>
</usages-collector> </usages-collector>
<usages-collector id="statistics.file.extensions.open"> <usages-collector id="statistics.file.extensions.open">
@@ -50,20 +52,7 @@
</session> </session>
</component> </component>
<component name="FileEditorManager"> <component name="FileEditorManager">
<leaf> <leaf SIDE_TABS_SIZE_LIMIT_KEY="300" />
<file pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/problem9.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="187">
<caret line="11" column="36" selection-start-line="11" selection-start-column="36" selection-end-line="11" selection-end-column="36" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
</leaf>
</component> </component>
<component name="FileTemplateManagerImpl"> <component name="FileTemplateManagerImpl">
<option name="RECENT_TEMPLATES"> <option name="RECENT_TEMPLATES">
@@ -104,8 +93,6 @@
<foldersAlwaysOnTop value="true" /> <foldersAlwaysOnTop value="true" />
</navigator> </navigator>
<panes> <panes>
<pane id="Scope" />
<pane id="PackagesPane" />
<pane id="ProjectPane"> <pane id="ProjectPane">
<subPane> <subPane>
<expand> <expand>
@@ -117,10 +104,13 @@
<select /> <select />
</subPane> </subPane>
</pane> </pane>
<pane id="Scope" />
<pane id="PackagesPane" />
</panes> </panes>
</component> </component>
<component name="PropertiesComponent"> <component name="PropertiesComponent">
<property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568706145579" /> <property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568706145579" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/../3/java" />
</component> </component>
<component name="RunDashboard"> <component name="RunDashboard">
<option name="ruleStates"> <option name="ruleStates">
@@ -164,17 +154,13 @@
<component name="ToolWindowManager"> <component name="ToolWindowManager">
<frame x="-8" y="-8" width="1936" height="1066" extended-state="6" /> <frame x="-8" y="-8" width="1936" height="1066" extended-state="6" />
<layout> <layout>
<window_info id="Image Layers" /> <window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.25266525" />
<window_info id="Designer" />
<window_info id="UI Designer" />
<window_info id="Capture Tool" />
<window_info id="Favorites" side_tool="true" />
<window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.25" />
<window_info id="Structure" order="1" side_tool="true" weight="0.25" /> <window_info id="Structure" order="1" side_tool="true" weight="0.25" />
<window_info anchor="bottom" id="Version Control" show_stripe_button="false" /> <window_info id="Image Layers" order="2" />
<window_info anchor="bottom" id="Terminal" /> <window_info id="Designer" order="3" />
<window_info anchor="bottom" id="Event Log" side_tool="true" /> <window_info id="UI Designer" order="4" />
<window_info anchor="bottom" id="Messages" weight="0.32939914" /> <window_info id="Capture Tool" order="5" />
<window_info id="Favorites" order="6" side_tool="true" />
<window_info anchor="bottom" id="Message" order="0" /> <window_info anchor="bottom" id="Message" order="0" />
<window_info anchor="bottom" id="Find" order="1" /> <window_info anchor="bottom" id="Find" order="1" />
<window_info anchor="bottom" id="Run" order="2" weight="0.32939914" /> <window_info anchor="bottom" id="Run" order="2" weight="0.32939914" />
@@ -182,14 +168,18 @@
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" /> <window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" /> <window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
<window_info anchor="bottom" id="TODO" order="6" /> <window_info anchor="bottom" id="TODO" order="6" />
<window_info anchor="right" id="Palette" /> <window_info anchor="bottom" id="Terminal" order="7" />
<window_info anchor="right" id="Theme Preview" /> <window_info anchor="bottom" id="Event Log" order="8" side_tool="true" />
<window_info anchor="right" id="Capture Analysis" /> <window_info anchor="bottom" id="Version Control" order="9" show_stripe_button="false" />
<window_info anchor="right" id="Palette&#9;" /> <window_info anchor="bottom" id="Messages" order="10" weight="0.32939914" />
<window_info anchor="right" id="Maven Projects" />
<window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" /> <window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
<window_info anchor="right" id="Ant Build" order="1" weight="0.25" /> <window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" /> <window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
<window_info anchor="right" id="Palette" order="3" />
<window_info anchor="right" id="Capture Analysis" order="4" />
<window_info anchor="right" id="Theme Preview" order="5" />
<window_info anchor="right" id="Palette&#9;" order="6" />
<window_info anchor="right" id="Maven Projects" order="7" />
</layout> </layout>
</component> </component>
<component name="VcsContentAnnotationSettings"> <component name="VcsContentAnnotationSettings">
@@ -205,8 +195,8 @@
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/problem9.java"> <entry file="file://$PROJECT_DIR$/src/problem9.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="187"> <state relative-caret-position="323">
<caret line="11" column="36" selection-start-line="11" selection-start-column="36" selection-end-line="11" selection-end-column="36" /> <caret line="19" column="40" selection-start-line="19" selection-start-column="40" selection-end-line="19" selection-end-column="40" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
</folding> </folding>