Skip to content

Commit 95930cc

Browse files
committed
Update solution file and remove link from directory
1 parent 612f4bf commit 95930cc

2 files changed

Lines changed: 3 additions & 7 deletions

File tree

DIRECTORY.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,6 @@
153153
* [Sol2](https://github.com/TheAlgorithms/Ruby/blob/master/project_euler/problem_004/sol2.rb)
154154
* Problem 005
155155
* [Sol1](https://github.com/TheAlgorithms/Ruby/blob/master/project_euler/problem_005/sol1.rb)
156-
* Problem 006
157-
* [Sol1](https://github.com/TheAlgorithms/Ruby/blob/master/project_euler/problem_006/sol1.rb)
158156
* Problem 020
159157
* [Sol1](https://github.com/TheAlgorithms/Ruby/blob/master/project_euler/problem_020/sol1.rb)
160158
* Problem 021

project_euler/problem_006/sol1.rb

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@
1111
#Find the difference between the sum of the squares of the first one
1212
#hundred natural numbers and the square of the sum.
1313

14-
def solution?(num)
14+
def solution?()
15+
num = 10
1516
x = 1
1617
y = 1
1718
result = 1
@@ -28,8 +29,5 @@ def solution?(num)
2829
r_sum_n_pow2 - r_n_pow2_plus_n_pow2
2930
end
3031

31-
answer = 0
32-
answer = solution?(10)
33-
34-
32+
answer = solution?()
3533
p answer

0 commit comments

Comments
 (0)