Build a Banner
Python
20 pts
Build a Banner
Build a banner for a festival using only += and *= to change the variables:
- Start with
banner = "Keren"and add" Festival"to it with+=. - Start with
border = "*"and repeat it with*=so it has exactly as many stars asbannerhas characters. Uselen(banner)— do not count by hand. - Print
border,banner,border.
Expected output:
************** Keren Festival **************
Checklist
- Add
" Festival"tobannerwith+=. - Repeat
borderwith*=so it has as many stars asbannerhas characters. - Print
border,banner,border.
🔑 Solution
If you view the solution before passing, you earn half points for this exercise. You still need to type it and press Check to finish.
How it works, step by step
Point at a step to highlight its lines. Type the solution yourself and press Check answer to finish.
