Star

Interview

Time limit1sMemory limit512 MB

Summary
Print a star pattern whose exact rule is inferred from sample outputs, with no trailing spaces on any line.
Level

Easy3 of 10

Topics
Implementation
Solved
No attempts yet

Problem

Look at the sample outputs and infer the star-printing rule, then print the stars.

Input

The first line gives the integer N (0 ≤ N ≤ 10).

Output

Print the stars according to the star-printing rule.

Do not print trailing spaces at the end of each line.

Examples5

  1. Example 1

    Input
    0
    
    Expected output
    *
    
  2. Example 2

    Input
    1
    
    Expected output
    **
    *
    
  3. Example 3

    Input
    2
    
    Expected output
    ****
    * *
    **
    *
    
  4. Example 4

    Input
    3
    
    Expected output
    ********
    * * * *
    **  **
    *   *
    ****
    * *
    **
    *
    
  5. Example 5

    Input
    4
    
    Expected output
    ****************
    * * * * * * * *
    **  **  **  **
    *   *   *   *
    ****    ****
    * *     * *
    **      **
    *       *
    ********
    * * * *
    **  **
    *   *
    ****
    * *
    **
    *