mirror of
https://github.com/Xevion/contest.git
synced 2025-12-09 14:06:49 -06:00
problem 4 restage
This commit is contained in:
6
uil/october-2013/4/.idea/misc.xml
generated
Normal file
6
uil/october-2013/4/.idea/misc.xml
generated
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8 (1)" project-jdk-type="JavaSDK">
|
||||
<output url="file://$PROJECT_DIR$/out" />
|
||||
</component>
|
||||
</project>
|
||||
8
uil/october-2013/4/.idea/modules.xml
generated
Normal file
8
uil/october-2013/4/.idea/modules.xml
generated
Normal file
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/4.iml" filepath="$PROJECT_DIR$/4.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
||||
238
uil/october-2013/4/.idea/workspace.xml
generated
Normal file
238
uil/october-2013/4/.idea/workspace.xml
generated
Normal file
@@ -0,0 +1,238 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="3abb2dc3-d281-4c87-b4d1-b95ea2036242" name="Default Changelist" comment="">
|
||||
<change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/input.dat" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/problem4.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/../../uil-practice-armstrong/java/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/../../uil-practice-armstrong/java/.idea/workspace.xml" afterDir="false" />
|
||||
</list>
|
||||
<ignored path="$PROJECT_DIR$/out/" />
|
||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="FUSProjectUsageTrigger">
|
||||
<session id="52736048">
|
||||
<usages-collector id="statistics.lifecycle.project">
|
||||
<counts>
|
||||
<entry key="project.open.time.2" value="1" />
|
||||
<entry key="project.opened" value="1" />
|
||||
</counts>
|
||||
</usages-collector>
|
||||
<usages-collector id="statistics.file.extensions.open">
|
||||
<counts>
|
||||
<entry key="dat" value="1" />
|
||||
<entry key="java" value="1" />
|
||||
</counts>
|
||||
</usages-collector>
|
||||
<usages-collector id="statistics.file.types.open">
|
||||
<counts>
|
||||
<entry key="JAVA" value="1" />
|
||||
<entry key="PLAIN_TEXT" value="1" />
|
||||
</counts>
|
||||
</usages-collector>
|
||||
<usages-collector id="statistics.file.extensions.edit">
|
||||
<counts>
|
||||
<entry key="dat" value="36" />
|
||||
<entry key="java" value="1038" />
|
||||
</counts>
|
||||
</usages-collector>
|
||||
<usages-collector id="statistics.file.types.edit">
|
||||
<counts>
|
||||
<entry key="JAVA" value="1038" />
|
||||
<entry key="PLAIN_TEXT" value="36" />
|
||||
</counts>
|
||||
</usages-collector>
|
||||
</session>
|
||||
</component>
|
||||
<component name="FileEditorManager">
|
||||
<leaf>
|
||||
<file pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/src/problem4.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="509">
|
||||
<caret line="30" column="30" selection-start-line="30" selection-start-column="30" selection-end-line="30" selection-end-column="30" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
</leaf>
|
||||
</component>
|
||||
<component name="FileTemplateManagerImpl">
|
||||
<option name="RECENT_TEMPLATES">
|
||||
<list>
|
||||
<option value="Class" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
<component name="Git.Settings">
|
||||
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$/../../.." />
|
||||
</component>
|
||||
<component name="GradleLocalSettings">
|
||||
<option name="projectSyncType">
|
||||
<map>
|
||||
<entry key="A:/Programming/Modding/Minecraft/EnderStorage" value="PREVIEW" />
|
||||
<entry key="A:/Programming/Modding/Minecraft/Fabric/fabric-example-mod" value="PREVIEW" />
|
||||
<entry key="A:/Programming/Modding/Minecraft/HelloWorldMod" value="PREVIEW" />
|
||||
</map>
|
||||
</option>
|
||||
</component>
|
||||
<component name="IdeDocumentHistory">
|
||||
<option name="CHANGED_PATHS">
|
||||
<list>
|
||||
<option value="$PROJECT_DIR$/input.dat" />
|
||||
<option value="$PROJECT_DIR$/src/problem4.java" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
<component name="ProjectFrameBounds" extendedState="6">
|
||||
<option name="x" value="-8" />
|
||||
<option name="y" value="-8" />
|
||||
<option name="width" value="1936" />
|
||||
<option name="height" value="1066" />
|
||||
</component>
|
||||
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
|
||||
<component name="ProjectView">
|
||||
<navigator proportions="" version="1">
|
||||
<foldersAlwaysOnTop value="true" />
|
||||
</navigator>
|
||||
<panes>
|
||||
<pane id="Scope" />
|
||||
<pane id="ProjectPane">
|
||||
<subPane>
|
||||
<expand>
|
||||
<path>
|
||||
<item name="4" type="b2602c69:ProjectViewProjectNode" />
|
||||
<item name="4" type="462c0819:PsiDirectoryNode" />
|
||||
</path>
|
||||
<path>
|
||||
<item name="4" type="b2602c69:ProjectViewProjectNode" />
|
||||
<item name="4" type="462c0819:PsiDirectoryNode" />
|
||||
<item name="src" type="462c0819:PsiDirectoryNode" />
|
||||
</path>
|
||||
</expand>
|
||||
<select />
|
||||
</subPane>
|
||||
</pane>
|
||||
<pane id="PackagesPane" />
|
||||
</panes>
|
||||
</component>
|
||||
<component name="PropertiesComponent">
|
||||
<property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568698188544" />
|
||||
</component>
|
||||
<component name="RunDashboard">
|
||||
<option name="ruleStates">
|
||||
<list>
|
||||
<RuleState>
|
||||
<option name="name" value="ConfigurationTypeDashboardGroupingRule" />
|
||||
</RuleState>
|
||||
<RuleState>
|
||||
<option name="name" value="StatusDashboardGroupingRule" />
|
||||
</RuleState>
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
<component name="RunManager">
|
||||
<configuration name="problem4" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true">
|
||||
<option name="MAIN_CLASS_NAME" value="problem4" />
|
||||
<module name="4" />
|
||||
<method v="2">
|
||||
<option name="Make" enabled="true" />
|
||||
</method>
|
||||
</configuration>
|
||||
<recent_temporary>
|
||||
<list>
|
||||
<item itemvalue="Application.problem4" />
|
||||
</list>
|
||||
</recent_temporary>
|
||||
</component>
|
||||
<component name="SvnConfiguration">
|
||||
<configuration />
|
||||
</component>
|
||||
<component name="TaskManager">
|
||||
<task active="true" id="Default" summary="Default task">
|
||||
<changelist id="3abb2dc3-d281-4c87-b4d1-b95ea2036242" name="Default Changelist" comment="" />
|
||||
<created>1568697525144</created>
|
||||
<option name="number" value="Default" />
|
||||
<option name="presentableId" value="Default" />
|
||||
<updated>1568697525144</updated>
|
||||
</task>
|
||||
<servers />
|
||||
</component>
|
||||
<component name="ToolWindowManager">
|
||||
<frame x="-8" y="-8" width="1936" height="1066" extended-state="6" />
|
||||
<editor active="true" />
|
||||
<layout>
|
||||
<window_info id="Image Layers" />
|
||||
<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 anchor="bottom" id="Version Control" show_stripe_button="false" />
|
||||
<window_info anchor="bottom" id="Terminal" />
|
||||
<window_info anchor="bottom" id="Event Log" 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="Find" order="1" />
|
||||
<window_info active="true" anchor="bottom" id="Run" order="2" visible="true" weight="0.32939914" />
|
||||
<window_info anchor="bottom" id="Debug" order="3" weight="0.4" />
|
||||
<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="TODO" order="6" />
|
||||
<window_info anchor="right" id="Palette" />
|
||||
<window_info anchor="right" id="Theme Preview" />
|
||||
<window_info anchor="right" id="Capture Analysis" />
|
||||
<window_info anchor="right" id="Palette	" />
|
||||
<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="Ant Build" order="1" weight="0.25" />
|
||||
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
|
||||
</layout>
|
||||
</component>
|
||||
<component name="VcsContentAnnotationSettings">
|
||||
<option name="myLimit" value="2678400000" />
|
||||
</component>
|
||||
<component name="editorHistoryManager">
|
||||
<entry file="file://$PROJECT_DIR$/input.dat">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="34">
|
||||
<caret line="2" column="12" lean-forward="true" selection-start-line="2" selection-start-column="12" selection-end-line="2" selection-end-column="12" />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/problem4.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="509">
|
||||
<caret line="30" column="30" selection-start-line="30" selection-start-column="30" selection-end-line="30" selection-end-column="30" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</component>
|
||||
<component name="masterDetails">
|
||||
<states>
|
||||
<state key="ProjectJDKs.UI">
|
||||
<settings>
|
||||
<last-edited>11</last-edited>
|
||||
<splitter-proportions>
|
||||
<option name="proportions">
|
||||
<list>
|
||||
<option value="0.2" />
|
||||
</list>
|
||||
</option>
|
||||
</splitter-proportions>
|
||||
</settings>
|
||||
</state>
|
||||
</states>
|
||||
</component>
|
||||
</project>
|
||||
11
uil/october-2013/4/4.iml
Normal file
11
uil/october-2013/4/4.iml
Normal file
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="JAVA_MODULE" version="4">
|
||||
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||
<exclude-output />
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
|
||||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
@@ -0,0 +1,4 @@
|
||||
3
|
||||
3 4 5 6 8
|
||||
10 12 10 5 6
|
||||
2 3 4 6 9
|
||||
BIN
uil/october-2013/4/out/production/4/problem4.class
Normal file
BIN
uil/october-2013/4/out/production/4/problem4.class
Normal file
Binary file not shown.
@@ -1,4 +1,34 @@
|
||||
package PACKAGE_NAME;
|
||||
import static java.lang.System.*;
|
||||
import java.util.Arrays;
|
||||
import java.util.Scanner;
|
||||
import java.io.File;
|
||||
import java.io.FileNotFoundException;
|
||||
|
||||
public class problem4 {
|
||||
public static void main(String[] args) throws FileNotFoundException {
|
||||
File input = new File("input.dat");
|
||||
Scanner read = new Scanner(input);
|
||||
int lines = read.nextInt();
|
||||
|
||||
for(int i = 0; i < lines; i++) {
|
||||
read.nextLine();
|
||||
int[] orig = new int[3];
|
||||
int[] partial = new int[3];
|
||||
orig[0] = read.nextInt();
|
||||
orig[1] = read.nextInt();
|
||||
orig[2] = read.nextInt();
|
||||
partial[0] = read.nextInt();
|
||||
partial[1] = read.nextInt();
|
||||
out.println(process(orig, partial));
|
||||
}
|
||||
}
|
||||
|
||||
static String process(int[] orig, int[] partial) {
|
||||
double multiplier = partial[0] / (double) orig[0];
|
||||
String output = "";
|
||||
partial[2] = (int)(orig[2] * multiplier);
|
||||
for(int sub : partial)
|
||||
output += sub + " ";
|
||||
return output;
|
||||
}
|
||||
}
|
||||
|
||||
18
uil/uil-practice-armstrong/java/.idea/workspace.xml
generated
18
uil/uil-practice-armstrong/java/.idea/workspace.xml
generated
@@ -1,9 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="5ee3d13c-335f-4b45-baa5-1d7b6e58ccd6" name="Default Changelist" comment="">
|
||||
<change beforePath="$PROJECT_DIR$/../../october-2013/3/input-generator/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/../../october-2013/3/input-generator/main.py" afterDir="false" />
|
||||
</list>
|
||||
<list default="true" id="5ee3d13c-335f-4b45-baa5-1d7b6e58ccd6" name="Default Changelist" comment="" />
|
||||
<ignored path="$PROJECT_DIR$/out/" />
|
||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
@@ -45,6 +43,7 @@
|
||||
<session id="-2041611852">
|
||||
<usages-collector id="statistics.lifecycle.project">
|
||||
<counts>
|
||||
<entry key="project.closed" value="1" />
|
||||
<entry key="project.open.time.0" value="1" />
|
||||
<entry key="project.opened" value="1" />
|
||||
</counts>
|
||||
@@ -66,8 +65,8 @@
|
||||
<file pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/src/question26.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="533">
|
||||
<caret line="43" column="62" selection-start-line="43" selection-start-column="62" selection-end-line="43" selection-end-column="62" />
|
||||
<state relative-caret-position="425">
|
||||
<caret line="27" column="20" selection-start-line="27" selection-start-column="20" selection-end-line="27" selection-end-column="20" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="e#435#436#0" expanded="true" />
|
||||
@@ -135,7 +134,7 @@
|
||||
</panes>
|
||||
</component>
|
||||
<component name="PropertiesComponent">
|
||||
<property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568696222928" />
|
||||
<property name="com.android.tools.idea.instantapp.provision.ProvisionBeforeRunTaskProvider.myTimeStamp" value="1568697422732" />
|
||||
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
|
||||
</component>
|
||||
<component name="RunDashboard">
|
||||
@@ -179,7 +178,6 @@
|
||||
</component>
|
||||
<component name="ToolWindowManager">
|
||||
<frame x="-8" y="-8" width="1936" height="1066" extended-state="6" />
|
||||
<editor active="true" />
|
||||
<layout>
|
||||
<window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.1881663" />
|
||||
<window_info id="Structure" order="1" side_tool="true" weight="0.25" />
|
||||
@@ -190,7 +188,7 @@
|
||||
<window_info id="Favorites" order="6" side_tool="true" />
|
||||
<window_info anchor="bottom" id="Message" order="0" />
|
||||
<window_info anchor="bottom" id="Find" order="1" />
|
||||
<window_info active="true" anchor="bottom" id="Run" order="2" visible="true" weight="0.2306867" />
|
||||
<window_info anchor="bottom" id="Run" order="2" weight="0.2306867" />
|
||||
<window_info anchor="bottom" id="Debug" order="3" weight="0.4" />
|
||||
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
|
||||
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
|
||||
@@ -215,8 +213,8 @@
|
||||
<component name="editorHistoryManager">
|
||||
<entry file="file://$PROJECT_DIR$/src/question26.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="533">
|
||||
<caret line="43" column="62" selection-start-line="43" selection-start-column="62" selection-end-line="43" selection-end-column="62" />
|
||||
<state relative-caret-position="425">
|
||||
<caret line="27" column="20" selection-start-line="27" selection-start-column="20" selection-end-line="27" selection-end-column="20" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="e#435#436#0" expanded="true" />
|
||||
|
||||
Reference in New Issue
Block a user