From 7beac799ef48e7769ac0fa07e4ebae8f22f55975 Mon Sep 17 00:00:00 2001 From: RussellDash332 Date: Mon, 24 Jun 2024 23:00:28 +0700 Subject: [PATCH] Second update as of 24 June 2024 --- README.md | 26 ++--- build.py | 4 + docs/index.html | 98 ++++++++++++++++--- src/Breaking Cake/breakingcake.py | 18 ++++ src/Cake/cake.py | 25 ++--- .../conveyorbelts2.py | 0 .../gatheringinyorknew.py | 15 +++ src/{Homework => Homework (2)}/homework.py | 0 src/Sudokunique/sudokunique.py | 45 +++++++++ .../target.py | 0 10 files changed, 192 insertions(+), 39 deletions(-) create mode 100644 src/Breaking Cake/breakingcake.py rename src/{Conveyor Belts => Conveyor Belts (2)}/conveyorbelts2.py (100%) create mode 100644 src/Gathering in Yorknew/gatheringinyorknew.py rename src/{Homework => Homework (2)}/homework.py (100%) create mode 100644 src/Sudokunique/sudokunique.py rename src/{Target Practice (2) => Target Practice (1)}/target.py (100%) diff --git a/README.md b/README.md index 7e682e18..d565ce83 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Kattis Solutions ![Visitors](https://count.getloli.com/get/@RussellDash332) -## Total problems solved: 2429 +## Total problems solved: 2433 Note that the tables below are auto-generated using [autokattis](https://github.com/RussellDash332/autokattis). @@ -294,6 +294,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Bread Sorting](https://open.kattis.com/problems/bread)| bread |4.8|[![py](images/python.png)]()| |[Breaking Bad](https://open.kattis.com/problems/breakingbad)| breakingbad |3.3|[![py](images/python.png)]()| |[Breaking Branches](https://open.kattis.com/problems/breakingbranches)| breakingbranches |1.7|[![py](images/python.png)]()| +|[Breaking Cake](https://open.kattis.com/problems/breakingcake)| breakingcake |5.7|[![py](images/python.png)](src/Breaking%20Cake/breakingcake.py)| |[Brexit](https://open.kattis.com/problems/brexit)| brexit |3.0|[![py](images/python.png)]()| |[Brexit Negotiations](https://open.kattis.com/problems/brexitnegotiations)| brexitnegotiations |5.2|[![py](images/python.png)]()| |[Bribe](https://open.kattis.com/problems/bribe)| bribe |5.6|[![py](images/python.png)](src/Bribe/bribe.py)| @@ -380,8 +381,8 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Catering](https://open.kattis.com/problems/catering)| catering |4.0|[![py](images/python.png)]()| |[A Feast For Cats](https://open.kattis.com/problems/cats)| cats |3.6|[![java](images/java.png)]()| |[Cat vs. Dog](https://open.kattis.com/problems/catvsdog)| catvsdog |6.0|[![py](images/python.png)](src/Cat%20vs.%20Dog/catvsdog.py)| -|[Cave Exploration](https://open.kattis.com/problems/caveexploration)| caveexploration |3.1|[![py](images/python.png)]()| -|[Cave Exploration](https://open.kattis.com/problems/caveexploration2)| caveexploration2 |4.0|[![py](images/python.png)]()| +|[Cave Exploration (1)](https://open.kattis.com/problems/caveexploration)| caveexploration |3.1|[![py](images/python.png)]()| +|[Cave Exploration (2)](https://open.kattis.com/problems/caveexploration2)| caveexploration2 |4.0|[![py](images/python.png)]()| |[CD](https://open.kattis.com/problems/cd)| cd |4.3|[![py](images/python.png)]()| |[Ceiling Function](https://open.kattis.com/problems/ceiling)| ceiling |2.2|[![py](images/python.png)]()| |[Celebrity Split](https://open.kattis.com/problems/celebritysplit)| celebritysplit |8.2|[![py](images/python.png)](src/Celebrity%20Split/celebritysplit.py)| @@ -511,8 +512,8 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Convex Hull (1)](https://open.kattis.com/problems/convexhull)| convexhull |4.1|[![py](images/python.png)]()| |[Convex Hull (2)](https://open.kattis.com/problems/convexhull2)| convexhull2 |7.1|[![py](images/python.png)](src/Convex%20Hull%20(2)/convexhull2.py)| |[Convex Polygon Area](https://open.kattis.com/problems/convexpolygonarea)| convexpolygonarea |2.0|[![cpp](images/cpp.png)]()| -|[Conveyor Belts](https://open.kattis.com/problems/conveyorbelts)| conveyorbelts |4.9|[![py](images/python.png)]()| -|[Conveyor Belts](https://open.kattis.com/problems/conveyorbelts2)| conveyorbelts2 |5.5|[![py](images/python.png)](src/Conveyor%20Belts/conveyorbelts2.py)| +|[Conveyor Belts (1)](https://open.kattis.com/problems/conveyorbelts)| conveyorbelts |4.9|[![py](images/python.png)]()| +|[Conveyor Belts (2)](https://open.kattis.com/problems/conveyorbelts2)| conveyorbelts2 |5.5|[![py](images/python.png)](src/Conveyor%20Belts%20(2)/conveyorbelts2.py)| |[Convoy](https://open.kattis.com/problems/convoy)| convoy |4.3|[![py](images/python.png)]()| |[Cookie Cutters](https://open.kattis.com/problems/cookiecutter)| cookiecutter |2.3|[![py](images/python.png)]()| |[Cookie Selection](https://open.kattis.com/problems/cookieselection)| cookieselection |5.0|[![java](images/java.png)]()| @@ -691,6 +692,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Driving Lanes](https://open.kattis.com/problems/drivinglanes)| drivinglanes |3.6|[![py](images/python.png)]()| |[Driving Range](https://open.kattis.com/problems/drivingrange)| drivingrange |3.9|[![java](images/java.png)]()| |[DRM Messages](https://open.kattis.com/problems/drmmessages)| drmmessages |1.6|[![cpp](images/cpp.png)]()| +|[Dropping Ball](https://open.kattis.com/problems/droppingball2)| droppingball2 |4.3|[![py](images/python.png)]()| |[Dropping Directions](https://open.kattis.com/problems/droppingdirections)| droppingdirections |3.7|[![py](images/python.png)]()| |[Drunk Vigenère](https://open.kattis.com/problems/drunkvigenere)| drunkvigenere |1.7|[![cpp](images/cpp.png)]()| |[Daylight Saving Time](https://open.kattis.com/problems/dst)| dst |2.2|[![py](images/python.png)]()| @@ -943,6 +945,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Gandalf's Spell](https://open.kattis.com/problems/gandalfsspell)| gandalfsspell |2.1|[![py](images/python.png)]()| |[Gangur](https://open.kattis.com/problems/gangur)| gangur |2.7|[![py](images/python.png)]()| |[Gas Station Numbers](https://open.kattis.com/problems/gasstationnumbers)| gasstationnumbers |7.9|[![py](images/python.png)](src/Gas%20Station%20Numbers/gasstationnumbers.py)| +|[Gathering in Yorknew](https://open.kattis.com/problems/gatheringinyorknew)| gatheringinyorknew |5.9|[![py](images/python.png)](src/Gathering%20in%20Yorknew/gatheringinyorknew.py)| |[GCD](https://open.kattis.com/problems/gcd)| gcd |1.5|[![py](images/python.png)]()| |[GCD and LCM](https://open.kattis.com/problems/gcdandlcm)| gcdandlcm |6.3|[![py](images/python.png)](src/GCD%20and%20LCM/gcdandlcm.py)| |[GCDs](https://open.kattis.com/problems/gcds)| gcds |5.0|[![py](images/python.png)]()| @@ -1058,7 +1061,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Heart Rate](https://open.kattis.com/problems/heartrate)| heartrate |1.5|[![cpp](images/cpp.png)]()| |[Heating Up](https://open.kattis.com/problems/heatingup)| heatingup |6.1|[![py](images/python.png)]()| |[Height Ordering](https://open.kattis.com/problems/height)| height |2.1|[![py](images/python.png)]()| -|[Homework](https://open.kattis.com/problems/heimavinna)| heimavinna |1.6|[![cpp](images/cpp.png)]()| +|[Homework (1)](https://open.kattis.com/problems/heimavinna)| heimavinna |1.6|[![cpp](images/cpp.png)]()| |[Heir's Dilemma](https://open.kattis.com/problems/heirsdilemma)| heirsdilemma |1.7|[![py](images/python.png)]()| |[Heliocentric](https://open.kattis.com/problems/heliocentric)| heliocentric |2.1|[![py](images/python.png)]()| |[Hello World!](https://open.kattis.com/problems/hello)| hello |1.1|[![c](images/c.png)]()[![cpp](images/cpp.png)]()[![go](images/go.png)]()[![java](images/java.png)]()[![js](images/javascript.png)]()[![kt](images/kotlin.png)]()[![php](images/php.png)]()[![py](images/python.png)]()[![rb](images/ruby.png)]()| @@ -1095,7 +1098,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Hogwarts](https://open.kattis.com/problems/hogwarts2)| hogwarts2 |5.1|[![py](images/python.png)]()| |[Holey N-Queens (Batman)](https://open.kattis.com/problems/holeynqueensbatman)| holeynqueensbatman |2.6|[![py](images/python.png)]()| |[Holiday Stars](https://open.kattis.com/problems/holidaystars)| holidaystars |6.0|[![py](images/python.png)](src/Holiday%20Stars/holidaystars.py)| -|[Homework](https://open.kattis.com/problems/homework)| homework |7.1|[![py](images/python.png)](src/Homework/homework.py)| +|[Homework (2)](https://open.kattis.com/problems/homework)| homework |7.1|[![py](images/python.png)](src/Homework%20(2)/homework.py)| |[Honeycomb Walk](https://open.kattis.com/problems/honey)| honey |2.9|[![py](images/python.png)]()| |[Honey Heist](https://open.kattis.com/problems/honeyheist)| honeyheist |3.5|[![py](images/python.png)]()| |[Honi](https://open.kattis.com/problems/honi)| honi |3.0|[![py](images/python.png)]()| @@ -1177,7 +1180,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Interplanetary Tunnels](https://open.kattis.com/problems/interplanetarytunnels)| interplanetarytunnels |2.2|[![py](images/python.png)]()| |[Interpreter](https://open.kattis.com/problems/interpreter)| interpreter |3.6|[![py](images/python.png)]()| |[Interval Cover](https://open.kattis.com/problems/intervalcover)| intervalcover |5.1|[![py](images/python.png)](src/Interval%20Cover/intervalcover.py)| -|[Interval Scheduling](https://open.kattis.com/problems/intervalscheduling)| intervalscheduling |1.8|[![java](images/java.png)]()[![py](images/python.png)]()| +|[Interval Scheduling (1)](https://open.kattis.com/problems/intervalscheduling)| intervalscheduling |1.8|[![java](images/java.png)]()[![py](images/python.png)]()| |[Interview Question](https://open.kattis.com/problems/interviewquestion)| interviewquestion |3.1|[![py](images/python.png)]()| |[Interview Queue](https://open.kattis.com/problems/interviewqueue)| interviewqueue |7.5|[![py](images/python.png)](src/Interview%20Queue/interviewqueue.py)| |[Integer Rotation](https://open.kattis.com/problems/introtation)| introtation |6.1|[![py](images/python.png)](src/Integer%20Rotation/introtation.py)| @@ -2131,6 +2134,7 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Subway Planning](https://open.kattis.com/problems/subwayplanning)| subwayplanning |2.2|[![py](images/python.png)]()| |[Successful Zoom](https://open.kattis.com/problems/successfulzoom)| successfulzoom |2.4|[![py](images/python.png)]()| |[Succession](https://open.kattis.com/problems/succession)| succession |3.1|[![py](images/python.png)]()| +|[Sudokunique](https://open.kattis.com/problems/sudokunique)| sudokunique |8.7|[![py](images/python.png)](src/Sudokunique/sudokunique.py)| |[Suffix Array Re-construction](https://open.kattis.com/problems/suffixarrayreconstruction)| suffixarrayreconstruction |3.9|[![py](images/python.png)](src/Suffix%20Array%20Re-construction/suffixarrayreconstruction.py)| |[Suffix Sorting](https://open.kattis.com/problems/suffixsorting)| suffixsorting |5.6|[![c](images/c.png)](src/Suffix%20Sorting/suffixsorting.c)[![cpp](images/cpp.png)](src/Suffix%20Sorting/suffixsorting.cpp)[![py](images/python.png)](src/Suffix%20Sorting/suffixsorting.py)| |[Šuma](https://open.kattis.com/problems/suma)| suma |6.4|[![py](images/python.png)](src/Šuma/suma.py)| @@ -2161,8 +2165,8 @@ For more Python data structure implementations, head over to [pytils](https://gi |[Tajna](https://open.kattis.com/problems/tajna)| tajna |2.1|[![py](images/python.png)]()| |[Takk fyrir mig](https://open.kattis.com/problems/takkfyrirmig)| takkfyrirmig |1.2|[![py](images/python.png)]()| |[Talnalás](https://open.kattis.com/problems/talnalas)| talnalas |4.0|[![py](images/python.png)]()| -|[Target Practice (2)](https://open.kattis.com/problems/target)| target |6.7|[![py](images/python.png)](src/Target%20Practice%20(2)/target.py)| -|[Target Practice (1)](https://open.kattis.com/problems/targetpractice)| targetpractice |4.6|[![py](images/python.png)]()| +|[Target Practice (1)](https://open.kattis.com/problems/target)| target |6.7|[![py](images/python.png)](src/Target%20Practice%20(1)/target.py)| +|[Target Practice (2)](https://open.kattis.com/problems/targetpractice)| targetpractice |4.6|[![py](images/python.png)]()| |[Tarifa](https://open.kattis.com/problems/tarifa)| tarifa |1.4|[![java](images/java.png)]()[![py](images/python.png)]()| |[Tautology](https://open.kattis.com/problems/tautology)| tautology |3.0|[![py](images/python.png)]()| |[Taxi Cab Scheme](https://open.kattis.com/problems/taxicab)| taxicab |5.8|[![py](images/python.png)](src/Taxi%20Cab%20Scheme/taxicab.py)| @@ -2461,7 +2465,7 @@ These problems can only be found in NUS Kattis and therefore do not contribute t |[Graph Data Structure 1](https://nus.kattis.com/problems/graphds1)| graphds1 |[![py](images/python.png)]()| |[Hard Array Problem](https://nus.kattis.com/problems/hardarray)| hardarray |[![java](images/java.png)]()| |[Hero Leveling](https://nus.kattis.com/problems/heroleveling)| heroleveling |[![cpp](images/cpp.png)]()| -|[Interval Scheduling](https://nus.kattis.com/problems/intervalscheduling2)| intervalscheduling2 |[![py](images/python.png)]()| +|[Interval Scheduling (2)](https://nus.kattis.com/problems/intervalscheduling2)| intervalscheduling2 |[![py](images/python.png)]()| |[Joining Points](https://nus.kattis.com/problems/joiningpoints)| joiningpoints |[![py](images/python.png)]()| |[Journey of the Repetitor](https://nus.kattis.com/problems/journeyoftherepetitor)| journeyoftherepetitor |[![py](images/python.png)]()| |[Key Item Recovery](https://nus.kattis.com/problems/keyitemrecovery)| keyitemrecovery |[![py](images/python.png)]()| diff --git a/build.py b/build.py index 3d3db89b..ee8fb3f1 100644 --- a/build.py +++ b/build.py @@ -38,6 +38,7 @@ nus_readme_contents = [] open_html_contents = [] nus_html_contents = [] +paths = set(); duplicate_paths = set() # Go through local files for main_dir in ['src', 'Secret']: @@ -104,8 +105,11 @@ else: open_readme_contents.append([pid, f"|[{path}]({url})| {pid} |{''.join(readme_image_links).replace(' ','%20')}|\n"]) open_html_contents.append([pid, url, path, html_image_links]) + if path in paths: duplicate_paths.add(path) + paths.add(path) # Sanity check before writing +assert not duplicate_paths, duplicate_paths assert not diff_mapper, diff_mapper assert not nus_problems, nus_problems print('Mapper exists:', diff_mapper != None) diff --git a/docs/index.html b/docs/index.html index 242954ea..1a45f151 100644 --- a/docs/index.html +++ b/docs/index.html @@ -5202,6 +5202,24 @@

+ + + + Breaking Cake + + + + breakingcake + + + 5.7 + + + + py + + + @@ -6777,7 +6795,7 @@

- Cave Exploration + Cave Exploration (1) @@ -6795,7 +6813,7 @@

- Cave Exploration + Cave Exploration (2) @@ -9150,7 +9168,7 @@

- Conveyor Belts + Conveyor Belts (1) @@ -9168,7 +9186,7 @@

- Conveyor Belts + Conveyor Belts (2) @@ -9178,7 +9196,7 @@

5.5 - + py @@ -12438,6 +12456,24 @@

+ + + + Dropping Ball + + + + droppingball2 + + + 4.3 + + + + py + + + @@ -17004,6 +17040,24 @@

+ + + + Gathering in Yorknew + + + + gatheringinyorknew + + + 5.9 + + + + py + + + @@ -19080,7 +19134,7 @@

- Homework + Homework (1) @@ -19770,7 +19824,7 @@

- Homework + Homework (2) @@ -19780,7 +19834,7 @@

7.1 - + py @@ -21249,7 +21303,7 @@

- Interval Scheduling + Interval Scheduling (1) @@ -38613,6 +38667,24 @@

+ + + + Sudokunique + + + + sudokunique + + + 8.7 + + + + py + + + @@ -39171,7 +39243,7 @@

- Target Practice (2) + Target Practice (1) @@ -39181,7 +39253,7 @@

6.7 - + py @@ -39189,7 +39261,7 @@

- Target Practice (1) + Target Practice (2) @@ -44468,7 +44540,7 @@

- Interval Scheduling + Interval Scheduling (2) diff --git a/src/Breaking Cake/breakingcake.py b/src/Breaking Cake/breakingcake.py new file mode 100644 index 00000000..71c20067 --- /dev/null +++ b/src/Breaking Cake/breakingcake.py @@ -0,0 +1,18 @@ +import sys; input = sys.stdin.readline; from collections import * +while True: + try: X, Y, Z, N = map(int, input().split()); R = {}; A = {} + except: break + for _ in range(N): + x, y, z = map(int, input().split()) + if x not in R: R[x] = {} + if y not in R[x]: R[x][y] = [] + R[x][y].append(z); A[(x, y, z)] = len(A) + print('YES'); sx = 1; mx = max(R); C = [None]*N + for x in sorted(R): + ex = x if x != mx else X; sy = 1; my = max(R[x]) + for y in sorted(R[x]): + ey = y if y != my else Y; sz = 1; mz = max(R[x][y]) + for z in sorted(R[x][y]): C[A[(x, y, z)]] = (sx, sy, sz, ex, ey, z if z != mz else Z); sz = z+1 + sy = y+1 + sx = x+1 + for c in C: print(*c) \ No newline at end of file diff --git a/src/Cake/cake.py b/src/Cake/cake.py index 00e50c11..1694320a 100644 --- a/src/Cake/cake.py +++ b/src/Cake/cake.py @@ -1,17 +1,12 @@ import sys; input = sys.stdin.readline -p, q, n = map(int, input().split()); r = [[] for _ in range(p)] -for _ in range(n): a, b = map(int, input().split()); r[a-1].append(b-1) -for i in r: i.sort() -sr = 0 -while True: - cr = sr - while cr < p and not r[cr]: cr += 1 - if cr == p: break - cr2 = cr+1 - while cr2 < p and not r[cr2]: cr2 += 1 - cs = cr if cr2 < p else p-1; x = 0 - for i in r[cr][:-1]: print(sr+1, x+1, cs+1, i+1); x = i+1 - if r[cr]: print(sr+1, x+1, cs+1, q) - sr = cr+1 - if sr == p: break +X, Y, N = map(int, input().split()); R = {} +for _ in range(N): + a, b = map(int, input().split()) + if a not in R: R[a] = [] + R[a].append(b) +sx = 1; mx = max(R) +for x in sorted(R): + ex = x if x != mx else X; sy = 1; my = max(R[x]) + for y in sorted(R[x]): print(sx, sy, ex, y if y != my else Y); sy = y+1 + sx = x+1 print(0) \ No newline at end of file diff --git a/src/Conveyor Belts/conveyorbelts2.py b/src/Conveyor Belts (2)/conveyorbelts2.py similarity index 100% rename from src/Conveyor Belts/conveyorbelts2.py rename to src/Conveyor Belts (2)/conveyorbelts2.py diff --git a/src/Gathering in Yorknew/gatheringinyorknew.py b/src/Gathering in Yorknew/gatheringinyorknew.py new file mode 100644 index 00000000..b595935d --- /dev/null +++ b/src/Gathering in Yorknew/gatheringinyorknew.py @@ -0,0 +1,15 @@ +import sys; input = sys.stdin.readline; from array import *; from bisect import * +N = int(input()); xP = []; xN = [] +for i in map(int, input().split()): + if i > 0: xP.append(i) + elif i < 0: xN.append(-i) +xP = array('i', sorted(xP)); xN = array('i', sorted(xN)); a = c = 0; b = d = 2*10**9+1; fP = [s:=0]+[(s:=s+i) for i in xP]; fN = [s:=0]+[(s:=s+i) for i in xN] +def f(k): return 2*(fP[z1:=bisect(xP, k/2)]-fP[z2:=bisect(xP, k)])+k*(2*z2-z1-len(xP)) +def g(k): return 2*(fN[z1:=bisect(xN, k/2)]-fN[z2:=bisect(xN, k)])+k*(2*z2-z1-len(xN)) +while b-a>2: + if f(μ:=b-(b-a)//3) >= f(λ:=a+(b-a)//3): b = μ + else: a = λ +while d-c>2: + if g(μ:=d-(d-c)//3) >= g(λ:=c+(d-c)//3): d = μ + else: c = λ +print(min(f(min(range(a-2, b+3), key=f)), g(min(range(c-2, d+3), key=g)))+fP[-1]+fN[-1]) \ No newline at end of file diff --git a/src/Homework/homework.py b/src/Homework (2)/homework.py similarity index 100% rename from src/Homework/homework.py rename to src/Homework (2)/homework.py diff --git a/src/Sudokunique/sudokunique.py b/src/Sudokunique/sudokunique.py new file mode 100644 index 00000000..27ca6e7a --- /dev/null +++ b/src/Sudokunique/sudokunique.py @@ -0,0 +1,45 @@ +from array import *; P = {1< 1: + if R[r]&v and C[c]&v and B[3*(r//3)+c//3]&v: R[r] ^= v; C[c] ^= v; B[3*(r//3)+c//3] ^= v + else: return print('Find another job') + for r in range(9): + for c in range(9): + if (x:=m[9*r+c]): + for i in range(9): V[y] = (V[y:=9*i+c]|E[x])^E[x]; V[y] = (V[y:=9*r+i]|E[x])^E[x] + for i in range(3): + for j in range(3): V[y] = (V[y:=9*(r//3*3+i)+c//3*3+j]|E[x])^E[x] + V[9*r+c] = 0 + def bt(s): + if not s: + if sol[0] != None and sol[0] != m: 1/0 + elif sol[0] == None: sol[0] = [*m] + return + rc = min(s, key=lambda x: BC[V[x]]); s.discard(rc); bm = V[rc]; r, c = divmod(rc, 9) + while bm: + v = bm&-bm; bm ^= v; m[rc] = P[v]; rm = [rc]; V[rc] ^= v + for i in range(9): + if v&V[9*i+c]: rm.append(9*i+c); V[9*i+c] ^= v + if v&V[9*r+i]: rm.append(9*r+i); V[9*r+i] ^= v + for i in range(3): + for j in range(3): + if v&V[9*(r//3*3+i)+c//3*3+j]: rm.append(9*(r//3*3+i)+c//3*3+j); V[9*(r//3*3+i)+c//3*3+j] ^= v + bt(s) + for x in rm: V[x] |= v + s.add(rc) + try: bt({i for i in range(81) if m[i]==0}) + except: return print('Non-unique') + if sol[0] == None: return print('Find another job') + print(*sol[0]) + +import sys; input = sys.stdin.readline +while 1: + m = [] + for _ in range(9): m.extend(map(int, input().split())) + input() + if not m: break + solve(m) \ No newline at end of file diff --git a/src/Target Practice (2)/target.py b/src/Target Practice (1)/target.py similarity index 100% rename from src/Target Practice (2)/target.py rename to src/Target Practice (1)/target.py