A Collection of Code Snippets in as Many Programming Languages as Possible
This project is maintained by TheRenegadeCoder
Welcome to the Baklava in Emojicode page! Here, you'll find the source code for this program as well as a description of how the program works.
π π
π Repeat a string
π str π‘ count π’ β‘οΈ π‘
π result = ""
ππ result π‘
π€π€ β‘οΈ π result
π for i = 0 to count - 1:
π i πβ© 0 countβοΈ π
π result += str
π€π§²resultπ§²π§²strπ§²π€ β‘οΈ π result
π
β©οΈ result
π β‘οΈ repeat_string
π for n = -10 to 10:
π n πβ© -10 11βοΈ π
π num_spaces = abs(n)
n β‘οΈ ππnum_spaces
βͺοΈ n βοΈ 0 π
num_spaces β¬
οΈ βοΈ -1
π
π num_stars = 21 - 2 * num_spaces
21 β 2 βοΈ num_spaces β‘οΈ num_stars
π Output num_spaces " ", num_stars "*"
βοΈrepeat_string π€ π€ num_spacesβοΈβ‘οΈ spaces
βοΈrepeat_string π€*π€ num_starsβοΈβ‘οΈ stars
π π€π§²spacesπ§²π§²starsπ§²π€ βοΈ
π
π
Baklava in Emojicode was written by:
If you see anything you'd like to change or update, please consider contributing.
No 'How to Implement the Solution' section available. Please consider contributing.
No 'How to Run the Solution' section available. Please consider contributing.