Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update 3.05.py #8

Merged
merged 1 commit into from
Oct 28, 2021
Merged

Update 3.05.py #8

merged 1 commit into from
Oct 28, 2021

Conversation

Pathik1618-boop
Copy link
Contributor

def my_func1():
print("+", 4*'-', '+', 4*'-', '+', 4*'-', '+')

def my_func2():
for x in range(4):
print('|', 4*' ', '|', 4*' ', '|', 4*' ', '|')

def total():
my_func1()
my_func2()
my_func1()
my_func2()
my_func1()
my_func2()
my_func1()

total()

@epequeno
Copy link
Owner

I'll merge this PR even though it's not quite correct, the question asked to produce this:

 + - - - - + - - - - +
 |         |         |
 |         |         |
 |         |         |
 |         |         |
 + - - - - + - - - - +
 |         |         |
 |         |         |
 |         |         |
 |         |         |
 + - - - - + - - - - +

But your solution produces:

+ ---- + ---- + ---- +
|      |      |      |
|      |      |      |
|      |      |      |
|      |      |      |
+ ---- + ---- + ---- +
|      |      |      |
|      |      |      |
|      |      |      |
|      |      |      |
+ ---- + ---- + ---- +
|      |      |      |
|      |      |      |
|      |      |      |
|      |      |      |
+ ---- + ---- + ---- +

Which is more correct than my current solution which seems very incorrect having tested it again just now.

Thanks for your submission! If you'd like to submit another PR to change your solution from a 3x3 grid to the requested 2x2 grid I'll accept that at any time 😄

@epequeno epequeno merged commit 1bdcdfe into epequeno:master Oct 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants