Skip to content

Commit

Permalink
Solution python
Browse files Browse the repository at this point in the history
Day1
  • Loading branch information
Keyvan-af committed Jan 15, 2024
1 parent 91d3f81 commit 7bf4c4e
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 0 deletions.
1 change: 1 addition & 0 deletions Python/Hello,World!/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
![Alt text](image.png)
Binary file added Python/Hello,World!/image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions Python/Hello,World!/solution.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
my_string = "Hello, World!"
print(my_string)
1 change: 1 addition & 0 deletions Python/Python If-Else/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
![Alt text](image.png)
Binary file added Python/Python If-Else/image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions Python/Python If-Else/solution.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/python3

import math
import os
import random
import re
import sys



if __name__ == '__main__':
n = int(input().strip())
if n % 2 == 1:
print("Weird")
else:
if 2 <= n <= 5:
print("Not Weird")
elif 6 <= n <= 20:
print("Weird")
else:
print("Not Weird")

0 comments on commit 7bf4c4e

Please sign in to comment.