Cake
Submit
Language is selected by the extension of the file. See the list of supported languages to know the extension of your language.
Problem
Challenge
Given an input n,
- print an ASCII art cake n layers tall,
- viewed from the side,
- with two candles on top,
- using box drawing characters.
- First layer is thinner than the others.
- Refer to the examples below.
- Example output
>> cake(1)
╭─╨─╨─╮
└─────┘
>> cake(2)
╭─╨─╨─╮
╭─┴─────┴─╮
│ │
└─────────┘
>> cake(3)
╭─╨─╨─╮
╭─┴─────┴─╮
│ │
╭─┴─────────┴─╮
│ │
└─────────────┘
>> cake(4)
╭─╨─╨─╮
╭─┴─────┴─╮
│ │
╭─┴─────────┴─╮
│ │
╭─┴─────────────┴─╮
│ │
└─────────────────┘
...and so on.
Options
rejudge feature is enabled
now post-mortem time, all source codes will be revealed
Sample input:_
1
Sample output:
╭─╨─╨─╮
└─────┘
Sample input:_
2
Sample output:
╭─╨─╨─╮
╭─┴─────┴─╮
│ │
└─────────┘
Sample input:_
3
Sample output:
╭─╨─╨─╮
╭─┴─────┴─╮
│ │
╭─┴─────────┴─╮
│ │
└─────────────┘
Ranking
Rank | User | Size | Time | Date | Statistics |
---|
1 | Jacob | 1462 | 0.2031 | 2016/09/22 09:01:14 | 132B / ?B / ?B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | whio | 348 | 0.2371 | 2016/10/01 01:58:01 | 294B / 3B / 1B |
2 | whio | 96 | 0.2558 | 2016/10/11 23:56:05 | 69B / 13B / 13B |
Language Ranking_
Rank | Lang | User | Size | Score |
1 | gs2 | whio | 96 | 10000 |
2 | Python | Sait2000 | 172 | 5581 |
3 | Python3 | Sait2000 | 194 | 4948 |
4 | C | julien_c | 287 | 3344 |
5 | Perl | rsFalse | 306 | 3137 |
6 | Ruby2 | Jacob | 1462 | 656 |
return to the top page