Progress Bar

1

2 votes
Very-Easy
Problem

Augustus has written a software which can download Media from websites. He was not very satisfied with the appearance of the softwareBut still, he felt his program was not very aesthetically pleasing, so he decided to include a download bar, like the one in the image. enter image description here

  • The download bar is divided into 20 parts, where each part represents 5%.
  • A vector represents the amount of media downloaded, Vector is made of '-' (See example)
  • Start and End of the bar should be denoted with '|'

Your task is to write a program, which simulates this function of the download bar.

Example:

Download bar for respective amount of completion looks like

0% : |                    |    (This download bar represents all values from 5% to 9%)
5% : |-                   |    (This download bar represents all values from 5% to 9%)
10%: |--                  |  (This download progress bar represents all values from 10% to 14%)
15%: |---                 | (This download progress bar represents all values from 15% to 19%)
18%: |---                |    (This download progress bar represents all values from 15% to 19%)
30%: |------              |

50%: |----------          |

100%: |--------------------|
Input Format

Input has one line, which contains an integer - X

X = Amount of data downloaded.

Constraints

0 <= X <= 100

Output Format

Displays the download bar for given amount of data downloaded, Refer example.

Time Limit: 0.1
Memory Limit: 256
Source Limit:
Editor Image

?