diff --git a/1.py b/codes/1.py similarity index 100% rename from 1.py rename to codes/1.py diff --git a/codes/10.py b/codes/10.py new file mode 100644 index 0000000..d69374c --- /dev/null +++ b/codes/10.py @@ -0,0 +1,6 @@ +n = int(input()) +sum = 0 +for i in range(n): + if((i+1) % 7 == 0 and (i+1) % 13 != 0): + sum += i+1 +print(sum) \ No newline at end of file diff --git a/2.py b/codes/2.py similarity index 100% rename from 2.py rename to codes/2.py diff --git a/3.py b/codes/3.py similarity index 100% rename from 3.py rename to codes/3.py diff --git a/4.py b/codes/4.py similarity index 100% rename from 4.py rename to codes/4.py diff --git a/5.py b/codes/5.py similarity index 100% rename from 5.py rename to codes/5.py diff --git a/codes/6.py b/codes/6.py new file mode 100644 index 0000000..c79ac63 --- /dev/null +++ b/codes/6.py @@ -0,0 +1,5 @@ +n = int(input()) +sum = 0 +for i in range(n): + sum += i+1 +print(sum) \ No newline at end of file diff --git a/codes/7.py b/codes/7.py new file mode 100644 index 0000000..6e4cafe --- /dev/null +++ b/codes/7.py @@ -0,0 +1,5 @@ +n = int(input()) +sum = 0 +for i in range(n): + sum += (i+1)**2 +print(sum) \ No newline at end of file diff --git a/codes/8.py b/codes/8.py new file mode 100644 index 0000000..557723c --- /dev/null +++ b/codes/8.py @@ -0,0 +1,6 @@ +n = int(input()) +sum = 0 +for i in range(n): + if((i+1) % 2==1): + sum += i+1 +print(sum) \ No newline at end of file diff --git a/codes/9.py b/codes/9.py new file mode 100644 index 0000000..9ac2fa7 --- /dev/null +++ b/codes/9.py @@ -0,0 +1,8 @@ +n = int(input()) +sum = 0 +for i in range(n): + tmp = 1 + for j in range(i+1): + tmp *= j+1 + sum += tmp +print(sum) \ No newline at end of file