PART 1: HORIZONTAL BAR GRAPH
Given an array of integers, create a horizontal bar graph where each entry translates into a row of dashes of that length (from top to bottom). For example, dataset [2, 1, 0, 1, 2, 4, 6] renders as:
--
-
-
--
----
------
PART 2: VERTICAL BAR GRAPH
Your users prefer vertical bar graphs, where each integer entry is shown as a column of |s (from left to right). Implement that so the dataset from Part 1 renders as:
|
|
||
||
| |||
|| ||||
Note that the third output line is blank to represent the 0 value.