diff --git a/ArithmeticAnalysis/Bisection.py b/arithmetic_analysis/bisection.py similarity index 100% rename from ArithmeticAnalysis/Bisection.py rename to arithmetic_analysis/bisection.py diff --git a/ArithmeticAnalysis/Intersection.py b/arithmetic_analysis/intersection.py similarity index 100% rename from ArithmeticAnalysis/Intersection.py rename to arithmetic_analysis/intersection.py diff --git a/ArithmeticAnalysis/LUdecomposition.py b/arithmetic_analysis/lu_decomposition.py similarity index 100% rename from ArithmeticAnalysis/LUdecomposition.py rename to arithmetic_analysis/lu_decomposition.py diff --git a/ArithmeticAnalysis/NewtonMethod.py b/arithmetic_analysis/newton_method.py similarity index 100% rename from ArithmeticAnalysis/NewtonMethod.py rename to arithmetic_analysis/newton_method.py diff --git a/ArithmeticAnalysis/NewtonRaphsonMethod.py b/arithmetic_analysis/newton_raphson_method.py similarity index 100% rename from ArithmeticAnalysis/NewtonRaphsonMethod.py rename to arithmetic_analysis/newton_raphson_method.py diff --git a/boolean_algebra/Quine_McCluskey/QuineMcCluskey.py b/boolean_algebra/quine_mc_cluskey/quine_mc_cluskey.py similarity index 100% rename from boolean_algebra/Quine_McCluskey/QuineMcCluskey.py rename to boolean_algebra/quine_mc_cluskey/quine_mc_cluskey.py diff --git a/data_structures/Binary Tree/binary_search_tree.py b/data_structures/binary_tree/binary_search_tree.py similarity index 100% rename from data_structures/Binary Tree/binary_search_tree.py rename to data_structures/binary_tree/binary_search_tree.py diff --git a/data_structures/Binary Tree/FenwickTree.py b/data_structures/binary_tree/fenwick_tree.py similarity index 100% rename from data_structures/Binary Tree/FenwickTree.py rename to data_structures/binary_tree/fenwick_tree.py diff --git a/data_structures/Binary Tree/LazySegmentTree.py b/data_structures/binary_tree/lazy_segment_tree.py similarity index 100% rename from data_structures/Binary Tree/LazySegmentTree.py rename to data_structures/binary_tree/lazy_segment_tree.py diff --git a/data_structures/Binary Tree/SegmentTree.py b/data_structures/binary_tree/segment_tree.py similarity index 100% rename from data_structures/Binary Tree/SegmentTree.py rename to data_structures/binary_tree/segment_tree.py diff --git a/data_structures/Graph/BellmanFord.py b/data_structures/graph/bellman_ford.py similarity index 100% rename from data_structures/Graph/BellmanFord.py rename to data_structures/graph/bellman_ford.py diff --git a/data_structures/Graph/BreadthFirstSearch.py b/data_structures/graph/breadth_first_search.py similarity index 100% rename from data_structures/Graph/BreadthFirstSearch.py rename to data_structures/graph/breadth_first_search.py diff --git a/data_structures/Graph/DepthFirstSearch.py b/data_structures/graph/depth_first_search.py similarity index 100% rename from data_structures/Graph/DepthFirstSearch.py rename to data_structures/graph/depth_first_search.py diff --git a/data_structures/Graph/FloydWarshall.py b/data_structures/graph/floyd_warshall.py similarity index 100% rename from data_structures/Graph/FloydWarshall.py rename to data_structures/graph/floyd_warshall.py diff --git a/data_structures/LinkedList/__init__.py b/data_structures/linked_list/__init__.py similarity index 100% rename from data_structures/LinkedList/__init__.py rename to data_structures/linked_list/__init__.py diff --git a/data_structures/LinkedList/DoublyLinkedList.py b/data_structures/linked_list/doubly_linked_list.py similarity index 100% rename from data_structures/LinkedList/DoublyLinkedList.py rename to data_structures/linked_list/doubly_linked_list.py diff --git a/data_structures/LinkedList/singly_LinkedList.py b/data_structures/linked_list/singly_linked_list.py similarity index 100% rename from data_structures/LinkedList/singly_LinkedList.py rename to data_structures/linked_list/singly_linked_list.py diff --git a/data_structures/Queue/QueueOnList.py b/data_structures/queue/queue_on_list.py similarity index 96% rename from data_structures/Queue/QueueOnList.py rename to data_structures/queue/queue_on_list.py index c8d0b41de5d5..2070274e2c55 100644 --- a/data_structures/Queue/QueueOnList.py +++ b/data_structures/queue/queue_on_list.py @@ -1,45 +1,45 @@ -"""Queue represented by a python list""" -class Queue(): - def __init__(self): - self.entries = [] - self.length = 0 - self.front=0 - - def __str__(self): - printed = '<' + str(self.entries)[1:-1] + '>' - return printed - - """Enqueues {@code item} - @param item - item to enqueue""" - def put(self, item): - self.entries.append(item) - self.length = self.length + 1 - - - """Dequeues {@code item} - @requirement: |self.length| > 0 - @return dequeued - item that was dequeued""" - def get(self): - self.length = self.length - 1 - dequeued = self.entries[self.front] - self.front-=1 - self.entries = self.entries[self.front:] - return dequeued - - """Rotates the queue {@code rotation} times - @param rotation - number of times to rotate queue""" - def rotate(self, rotation): - for i in range(rotation): - self.put(self.get()) - - """Enqueues {@code item} - @return item at front of self.entries""" - def front(self): - return self.entries[0] - - """Returns the length of this.entries""" - def size(self): - return self.length +"""Queue represented by a python list""" +class Queue(): + def __init__(self): + self.entries = [] + self.length = 0 + self.front=0 + + def __str__(self): + printed = '<' + str(self.entries)[1:-1] + '>' + return printed + + """Enqueues {@code item} + @param item + item to enqueue""" + def put(self, item): + self.entries.append(item) + self.length = self.length + 1 + + + """Dequeues {@code item} + @requirement: |self.length| > 0 + @return dequeued + item that was dequeued""" + def get(self): + self.length = self.length - 1 + dequeued = self.entries[self.front] + self.front-=1 + self.entries = self.entries[self.front:] + return dequeued + + """Rotates the queue {@code rotation} times + @param rotation + number of times to rotate queue""" + def rotate(self, rotation): + for i in range(rotation): + self.put(self.get()) + + """Enqueues {@code item} + @return item at front of self.entries""" + def front(self): + return self.entries[0] + + """Returns the length of this.entries""" + def size(self): + return self.length diff --git a/data_structures/Queue/QueueOnPseudoStack.py b/data_structures/queue/queue_on_pseudo_stack.py similarity index 96% rename from data_structures/Queue/QueueOnPseudoStack.py rename to data_structures/queue/queue_on_pseudo_stack.py index b69fbcc988f7..fe302736e8d2 100644 --- a/data_structures/Queue/QueueOnPseudoStack.py +++ b/data_structures/queue/queue_on_pseudo_stack.py @@ -1,50 +1,50 @@ -"""Queue represented by a pseudo stack (represented by a list with pop and append)""" -class Queue(): - def __init__(self): - self.stack = [] - self.length = 0 - - def __str__(self): - printed = '<' + str(self.stack)[1:-1] + '>' - return printed - - """Enqueues {@code item} - @param item - item to enqueue""" - def put(self, item): - self.stack.append(item) - self.length = self.length + 1 - - """Dequeues {@code item} - @requirement: |self.length| > 0 - @return dequeued - item that was dequeued""" - def get(self): - self.rotate(1) - dequeued = self.stack[self.length-1] - self.stack = self.stack[:-1] - self.rotate(self.length-1) - self.length = self.length -1 - return dequeued - - """Rotates the queue {@code rotation} times - @param rotation - number of times to rotate queue""" - def rotate(self, rotation): - for i in range(rotation): - temp = self.stack[0] - self.stack = self.stack[1:] - self.put(temp) - self.length = self.length - 1 - - """Reports item at the front of self - @return item at front of self.stack""" - def front(self): - front = self.get() - self.put(front) - self.rotate(self.length-1) - return front - - """Returns the length of this.stack""" - def size(self): - return self.length +"""Queue represented by a pseudo stack (represented by a list with pop and append)""" +class Queue(): + def __init__(self): + self.stack = [] + self.length = 0 + + def __str__(self): + printed = '<' + str(self.stack)[1:-1] + '>' + return printed + + """Enqueues {@code item} + @param item + item to enqueue""" + def put(self, item): + self.stack.append(item) + self.length = self.length + 1 + + """Dequeues {@code item} + @requirement: |self.length| > 0 + @return dequeued + item that was dequeued""" + def get(self): + self.rotate(1) + dequeued = self.stack[self.length-1] + self.stack = self.stack[:-1] + self.rotate(self.length-1) + self.length = self.length -1 + return dequeued + + """Rotates the queue {@code rotation} times + @param rotation + number of times to rotate queue""" + def rotate(self, rotation): + for i in range(rotation): + temp = self.stack[0] + self.stack = self.stack[1:] + self.put(temp) + self.length = self.length - 1 + + """Reports item at the front of self + @return item at front of self.stack""" + def front(self): + front = self.get() + self.put(front) + self.rotate(self.length-1) + return front + + """Returns the length of this.stack""" + def size(self): + return self.length diff --git a/data_structures/UnionFind/__init__.py b/data_structures/union_find/__init__.py similarity index 100% rename from data_structures/UnionFind/__init__.py rename to data_structures/union_find/__init__.py diff --git a/data_structures/UnionFind/tests_union_find.py b/data_structures/union_find/tests_union_find.py similarity index 100% rename from data_structures/UnionFind/tests_union_find.py rename to data_structures/union_find/tests_union_find.py diff --git a/data_structures/UnionFind/union_find.py b/data_structures/union_find/union_find.py similarity index 100% rename from data_structures/UnionFind/union_find.py rename to data_structures/union_find/union_find.py diff --git a/dynamic_programming/FloydWarshall.py b/dynamic_programming/floyd_warshall.py similarity index 96% rename from dynamic_programming/FloydWarshall.py rename to dynamic_programming/floyd_warshall.py index 038499ca03b6..0f4e16cd91d7 100644 --- a/dynamic_programming/FloydWarshall.py +++ b/dynamic_programming/floyd_warshall.py @@ -1,37 +1,37 @@ -import math - -class Graph: - - def __init__(self, N = 0): # a graph with Node 0,1,...,N-1 - self.N = N - self.W = [[math.inf for j in range(0,N)] for i in range(0,N)] # adjacency matrix for weight - self.dp = [[math.inf for j in range(0,N)] for i in range(0,N)] # dp[i][j] stores minimum distance from i to j - - def addEdge(self, u, v, w): - self.dp[u][v] = w - - def floyd_warshall(self): - for k in range(0,self.N): - for i in range(0,self.N): - for j in range(0,self.N): - self.dp[i][j] = min(self.dp[i][j], self.dp[i][k] + self.dp[k][j]) - - def showMin(self, u, v): - return self.dp[u][v] - -if __name__ == '__main__': - graph = Graph(5) - graph.addEdge(0,2,9) - graph.addEdge(0,4,10) - graph.addEdge(1,3,5) - graph.addEdge(2,3,7) - graph.addEdge(3,0,10) - graph.addEdge(3,1,2) - graph.addEdge(3,2,1) - graph.addEdge(3,4,6) - graph.addEdge(4,1,3) - graph.addEdge(4,2,4) - graph.addEdge(4,3,9) - graph.floyd_warshall() - graph.showMin(1,4) - graph.showMin(0,3) +import math + +class Graph: + + def __init__(self, N = 0): # a graph with Node 0,1,...,N-1 + self.N = N + self.W = [[math.inf for j in range(0,N)] for i in range(0,N)] # adjacency matrix for weight + self.dp = [[math.inf for j in range(0,N)] for i in range(0,N)] # dp[i][j] stores minimum distance from i to j + + def addEdge(self, u, v, w): + self.dp[u][v] = w + + def floyd_warshall(self): + for k in range(0,self.N): + for i in range(0,self.N): + for j in range(0,self.N): + self.dp[i][j] = min(self.dp[i][j], self.dp[i][k] + self.dp[k][j]) + + def showMin(self, u, v): + return self.dp[u][v] + +if __name__ == '__main__': + graph = Graph(5) + graph.addEdge(0,2,9) + graph.addEdge(0,4,10) + graph.addEdge(1,3,5) + graph.addEdge(2,3,7) + graph.addEdge(3,0,10) + graph.addEdge(3,1,2) + graph.addEdge(3,2,1) + graph.addEdge(3,4,6) + graph.addEdge(4,1,3) + graph.addEdge(4,2,4) + graph.addEdge(4,3,9) + graph.floyd_warshall() + graph.showMin(1,4) + graph.showMin(0,3) diff --git a/linear-algebra-python/src/lib.pyc b/linear-algebra-python/src/lib.pyc deleted file mode 100644 index 7aeca0e1c6d5..000000000000 Binary files a/linear-algebra-python/src/lib.pyc and /dev/null differ diff --git a/linear-algebra-python/README.md b/linear_algebra_python/README.md similarity index 100% rename from linear-algebra-python/README.md rename to linear_algebra_python/README.md diff --git a/linear-algebra-python/src/lib.py b/linear_algebra_python/src/lib.py similarity index 100% rename from linear-algebra-python/src/lib.py rename to linear_algebra_python/src/lib.py diff --git a/linear-algebra-python/src/tests.py b/linear_algebra_python/src/tests.py similarity index 100% rename from linear-algebra-python/src/tests.py rename to linear_algebra_python/src/tests.py diff --git a/Maths/ModularExponential.py b/maths/modular_exponential.py similarity index 100% rename from Maths/ModularExponential.py rename to maths/modular_exponential.py diff --git a/Maths/SimpsonRule.py b/maths/simpson_rule.py similarity index 100% rename from Maths/SimpsonRule.py rename to maths/simpson_rule.py diff --git a/Maths/TrapezoidalRule.py b/maths/trapezoidal_rule.py similarity index 100% rename from Maths/TrapezoidalRule.py rename to maths/trapezoidal_rule.py diff --git a/other/FindingPrimes.py b/other/finding_primes.py similarity index 100% rename from other/FindingPrimes.py rename to other/finding_primes.py diff --git a/other/Fischer-Yates_Shuffle.py b/other/fischer_yates_shuffle.py similarity index 100% rename from other/Fischer-Yates_Shuffle.py rename to other/fischer_yates_shuffle.py diff --git a/other/LinearCongruentialGenerator.py b/other/linear_congruential_generator.py similarity index 100% rename from other/LinearCongruentialGenerator.py rename to other/linear_congruential_generator.py diff --git a/Project Euler/README.md b/project_euler/README.md similarity index 100% rename from Project Euler/README.md rename to project_euler/README.md diff --git a/Project Euler/Problem 01/sol1.py b/project_euler/problem_01/sol1.py similarity index 100% rename from Project Euler/Problem 01/sol1.py rename to project_euler/problem_01/sol1.py diff --git a/Project Euler/Problem 01/sol2.py b/project_euler/problem_01/sol2.py similarity index 100% rename from Project Euler/Problem 01/sol2.py rename to project_euler/problem_01/sol2.py diff --git a/Project Euler/Problem 01/sol3.py b/project_euler/problem_01/sol3.py similarity index 100% rename from Project Euler/Problem 01/sol3.py rename to project_euler/problem_01/sol3.py diff --git a/Project Euler/Problem 01/sol4.py b/project_euler/problem_01/sol4.py similarity index 94% rename from Project Euler/Problem 01/sol4.py rename to project_euler/problem_01/sol4.py index 7941f5fcd3fe..36a91e7043aa 100644 --- a/Project Euler/Problem 01/sol4.py +++ b/project_euler/problem_01/sol4.py @@ -1,30 +1,30 @@ -def mulitples(limit): - xmulti = [] - zmulti = [] - z = 3 - x = 5 - temp = 1 - while True: - result = z * temp - if (result < limit): - zmulti.append(result) - temp += 1 - else: - temp = 1 - break - while True: - result = x * temp - if (result < limit): - xmulti.append(result) - temp += 1 - else: - break - collection = list(set(xmulti+zmulti)) - return (sum(collection)) - - - - - - -print (mulitples(1000)) +def mulitples(limit): + xmulti = [] + zmulti = [] + z = 3 + x = 5 + temp = 1 + while True: + result = z * temp + if (result < limit): + zmulti.append(result) + temp += 1 + else: + temp = 1 + break + while True: + result = x * temp + if (result < limit): + xmulti.append(result) + temp += 1 + else: + break + collection = list(set(xmulti+zmulti)) + return (sum(collection)) + + + + + + +print (mulitples(1000)) diff --git a/Project Euler/Problem 02/sol1.py b/project_euler/problem_02/sol1.py similarity index 100% rename from Project Euler/Problem 02/sol1.py rename to project_euler/problem_02/sol1.py diff --git a/Project Euler/Problem 02/sol2.py b/project_euler/problem_02/sol2.py similarity index 95% rename from Project Euler/Problem 02/sol2.py rename to project_euler/problem_02/sol2.py index 9bbd0c535d63..a56b6c7a8782 100644 --- a/Project Euler/Problem 02/sol2.py +++ b/project_euler/problem_02/sol2.py @@ -1,12 +1,12 @@ -def fib(n): - a, b, s = 0, 1, 0 - while b < n: - if b % 2 == 0 and b < n: s += b - a, b = b, a+b - ls.append(s) - -T = int(input().strip()) -ls = [] -for _ in range(T): - fib(int(input().strip())) -print(*ls, sep = '\n') +def fib(n): + a, b, s = 0, 1, 0 + while b < n: + if b % 2 == 0 and b < n: s += b + a, b = b, a+b + ls.append(s) + +T = int(input().strip()) +ls = [] +for _ in range(T): + fib(int(input().strip())) +print(*ls, sep = '\n') diff --git a/Project Euler/Problem 02/sol3.py b/project_euler/problem_02/sol3.py similarity index 100% rename from Project Euler/Problem 02/sol3.py rename to project_euler/problem_02/sol3.py diff --git a/Project Euler/Problem 03/sol1.py b/project_euler/problem_03/sol1.py similarity index 100% rename from Project Euler/Problem 03/sol1.py rename to project_euler/problem_03/sol1.py diff --git a/Project Euler/Problem 03/sol2.py b/project_euler/problem_03/sol2.py similarity index 100% rename from Project Euler/Problem 03/sol2.py rename to project_euler/problem_03/sol2.py diff --git a/Project Euler/Problem 04/sol1.py b/project_euler/problem_04/sol1.py similarity index 100% rename from Project Euler/Problem 04/sol1.py rename to project_euler/problem_04/sol1.py diff --git a/Project Euler/Problem 04/sol2.py b/project_euler/problem_04/sol2.py similarity index 100% rename from Project Euler/Problem 04/sol2.py rename to project_euler/problem_04/sol2.py diff --git a/Project Euler/Problem 05/sol1.py b/project_euler/problem_05/sol1.py similarity index 100% rename from Project Euler/Problem 05/sol1.py rename to project_euler/problem_05/sol1.py diff --git a/Project Euler/Problem 05/sol2.py b/project_euler/problem_05/sol2.py similarity index 100% rename from Project Euler/Problem 05/sol2.py rename to project_euler/problem_05/sol2.py diff --git a/Project Euler/Problem 06/sol1.py b/project_euler/problem_06/sol1.py similarity index 100% rename from Project Euler/Problem 06/sol1.py rename to project_euler/problem_06/sol1.py diff --git a/Project Euler/Problem 06/sol2.py b/project_euler/problem_06/sol2.py similarity index 100% rename from Project Euler/Problem 06/sol2.py rename to project_euler/problem_06/sol2.py diff --git a/Project Euler/Problem 07/sol1.py b/project_euler/problem_07/sol1.py similarity index 100% rename from Project Euler/Problem 07/sol1.py rename to project_euler/problem_07/sol1.py diff --git a/Project Euler/Problem 07/sol2.py b/project_euler/problem_07/sol2.py similarity index 100% rename from Project Euler/Problem 07/sol2.py rename to project_euler/problem_07/sol2.py diff --git a/Project Euler/Problem 08/sol1.py b/project_euler/problem_08/sol1.py similarity index 100% rename from Project Euler/Problem 08/sol1.py rename to project_euler/problem_08/sol1.py diff --git a/Project Euler/Problem 10/sol1.py b/project_euler/problem_10/sol1.py similarity index 100% rename from Project Euler/Problem 10/sol1.py rename to project_euler/problem_10/sol1.py diff --git a/Project Euler/Problem 11/grid.txt b/project_euler/problem_11/grid.txt similarity index 100% rename from Project Euler/Problem 11/grid.txt rename to project_euler/problem_11/grid.txt diff --git a/Project Euler/Problem 11/sol1.py b/project_euler/problem_11/sol1.py similarity index 100% rename from Project Euler/Problem 11/sol1.py rename to project_euler/problem_11/sol1.py diff --git a/Project Euler/Problem 11/sol2.py b/project_euler/problem_11/sol2.py similarity index 100% rename from Project Euler/Problem 11/sol2.py rename to project_euler/problem_11/sol2.py diff --git a/Project Euler/Problem 12/sol1.py b/project_euler/problem_12/sol1.py similarity index 100% rename from Project Euler/Problem 12/sol1.py rename to project_euler/problem_12/sol1.py diff --git a/Project Euler/Problem 13/sol1.py b/project_euler/problem_13/sol1.py similarity index 100% rename from Project Euler/Problem 13/sol1.py rename to project_euler/problem_13/sol1.py diff --git a/Project Euler/Problem 14/sol1.py b/project_euler/problem_14/sol1.py similarity index 100% rename from Project Euler/Problem 14/sol1.py rename to project_euler/problem_14/sol1.py diff --git a/Project Euler/Problem 15/sol1.py b/project_euler/problem_15/sol1.py similarity index 100% rename from Project Euler/Problem 15/sol1.py rename to project_euler/problem_15/sol1.py diff --git a/Project Euler/Problem 16/sol1.py b/project_euler/problem_16/sol1.py similarity index 100% rename from Project Euler/Problem 16/sol1.py rename to project_euler/problem_16/sol1.py diff --git a/Project Euler/Problem 17/sol1.py b/project_euler/problem_17/sol1.py similarity index 100% rename from Project Euler/Problem 17/sol1.py rename to project_euler/problem_17/sol1.py diff --git a/Project Euler/Problem 19/sol1.py b/project_euler/problem_19/sol1.py similarity index 100% rename from Project Euler/Problem 19/sol1.py rename to project_euler/problem_19/sol1.py diff --git a/Project Euler/Problem 20/sol1.py b/project_euler/problem_20/sol1.py similarity index 100% rename from Project Euler/Problem 20/sol1.py rename to project_euler/problem_20/sol1.py diff --git a/Project Euler/Problem 20/sol2.py b/project_euler/problem_20/sol2.py similarity index 100% rename from Project Euler/Problem 20/sol2.py rename to project_euler/problem_20/sol2.py diff --git a/Project Euler/Problem 21/sol1.py b/project_euler/problem_21/sol1.py similarity index 100% rename from Project Euler/Problem 21/sol1.py rename to project_euler/problem_21/sol1.py diff --git a/Project Euler/Problem 22/p022_names.txt b/project_euler/problem_22/p022_names.txt similarity index 100% rename from Project Euler/Problem 22/p022_names.txt rename to project_euler/problem_22/p022_names.txt diff --git a/Project Euler/Problem 22/sol1.py b/project_euler/problem_22/sol1.py similarity index 100% rename from Project Euler/Problem 22/sol1.py rename to project_euler/problem_22/sol1.py diff --git a/Project Euler/Problem 22/sol2.py b/project_euler/problem_22/sol2.py similarity index 100% rename from Project Euler/Problem 22/sol2.py rename to project_euler/problem_22/sol2.py diff --git a/Project Euler/Problem 24/sol1.py b/project_euler/problem_24/sol1.py similarity index 100% rename from Project Euler/Problem 24/sol1.py rename to project_euler/problem_24/sol1.py diff --git a/Project Euler/Problem 25/sol1.py b/project_euler/problem_25/sol1.py similarity index 100% rename from Project Euler/Problem 25/sol1.py rename to project_euler/problem_25/sol1.py diff --git a/Project Euler/Problem 28/sol1.py b/project_euler/problem_28/sol1.py similarity index 100% rename from Project Euler/Problem 28/sol1.py rename to project_euler/problem_28/sol1.py diff --git a/Project Euler/Problem 29/solution.py b/project_euler/problem_29/solution.py similarity index 100% rename from Project Euler/Problem 29/solution.py rename to project_euler/problem_29/solution.py diff --git a/Project Euler/Problem 36/sol1.py b/project_euler/problem_36/sol1.py similarity index 100% rename from Project Euler/Problem 36/sol1.py rename to project_euler/problem_36/sol1.py diff --git a/Project Euler/Problem 40/sol1.py b/project_euler/problem_40/sol1.py similarity index 100% rename from Project Euler/Problem 40/sol1.py rename to project_euler/problem_40/sol1.py diff --git a/Project Euler/Problem 48/sol1.py b/project_euler/problem_48/sol1.py similarity index 100% rename from Project Euler/Problem 48/sol1.py rename to project_euler/problem_48/sol1.py diff --git a/Project Euler/Problem 52/sol1.py b/project_euler/problem_52/sol1.py similarity index 100% rename from Project Euler/Problem 52/sol1.py rename to project_euler/problem_52/sol1.py diff --git a/Project Euler/Problem 53/sol1.py b/project_euler/problem_53/sol1.py similarity index 100% rename from Project Euler/Problem 53/sol1.py rename to project_euler/problem_53/sol1.py diff --git a/Project Euler/Problem 76/sol1.py b/project_euler/problem_76/sol1.py similarity index 100% rename from Project Euler/Problem 76/sol1.py rename to project_euler/problem_76/sol1.py diff --git a/Project Euler/Problem 9/sol1.py b/project_euler/problem_9/sol1.py similarity index 100% rename from Project Euler/Problem 9/sol1.py rename to project_euler/problem_9/sol1.py diff --git a/Project Euler/Problem 9/sol2.py b/project_euler/problem_9/sol2.py similarity index 100% rename from Project Euler/Problem 9/sol2.py rename to project_euler/problem_9/sol2.py diff --git a/simple-client-server/README.md b/simple_client_server/README.md similarity index 100% rename from simple-client-server/README.md rename to simple_client_server/README.md diff --git a/simple-client-server/client.py b/simple_client_server/client.py similarity index 100% rename from simple-client-server/client.py rename to simple_client_server/client.py diff --git a/simple-client-server/server.py b/simple_client_server/server.py similarity index 100% rename from simple-client-server/server.py rename to simple_client_server/server.py diff --git a/sorts/external-sort.py b/sorts/external_sort.py similarity index 100% rename from sorts/external-sort.py rename to sorts/external_sort.py diff --git a/strings/knuth-morris-pratt.py b/strings/knuth_morris_pratt.py similarity index 100% rename from strings/knuth-morris-pratt.py rename to strings/knuth_morris_pratt.py diff --git a/strings/min-cost-string-conversion.py b/strings/min_cost_string_conversion.py similarity index 100% rename from strings/min-cost-string-conversion.py rename to strings/min_cost_string_conversion.py diff --git a/strings/rabin-karp.py b/strings/rabin_karp.py similarity index 100% rename from strings/rabin-karp.py rename to strings/rabin_karp.py