DWITE Online Computer Programming Contest, February 2008, Problem 1
Just in time for Valentine's Day 2008, we require an ASCII heart generator. Based on Tony's horrible "artwork" below:
~.~
` `
\./
The input will contain 5 lines, integers .
The output will contain 5 sets of 3 lines, 15 in total. Each set will have a specified number of hearts generated. Refer to the sample output for examples.
Note: each heart is made up of 3 lines, 5 characters each. Don't forget to have all the spaces at the end.
Sample Input
1
0
3
Sample Output
~.~
` `
\./
~.~ ~.~ ~.~
` `` `` `
\./ \./ \./
Problem Resource: DWITE
Comments
emmmm why i cannot print "\" ??? :-(
https://en.wikipedia.org/wiki/Escape_sequences_in_C
Thank you! :-)