H Lecture Notes - Lecture 1: Natural Number

10 views1 pages

Document Summary

Mr. vincent works in a door mat manufacturing company. One day, he designed a new door mat with the following specifications: Mat size must be x. ( is an odd natural number, and is times . ) The design should have "welcome" written in the center. The design pattern should only use |, . and - characters. # designer door mat in python - hackerrank solution start. N, m = map(int, input(). split()) for i in range(1, n, 2): print(str(". |. " * i). center(m, "-")) print("welcome". center(m, "-")) for i in range(n-2, -1, -2): print(str(". |. "

Get access

Grade+
$40 USD/m
Billed monthly
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
10 Verified Answers
Class+
$30 USD/m
Billed monthly
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
7 Verified Answers

Related Documents