[Question]
  [
Take two lists of non-negative integers, and output an ASCII-box as it's defined below.
* Corners and intersections are pluses: `+` (ASCII-code 43)
* Vertical lines are bars `|` (ASCII-code 124)
* Horizontal lines are minuses `-` (ASCII-code 45)
The first input list specifies the number of minuses between each plus sign, in the horizontal direction.
The second input list specifies the number of bars between each plus sign, in the vertical direction.
It's easier to explain with a few examples:
```
0    // No minuses between each + sign
0    // No bars between + signs
++
++
------------------
1 2   // First a single minus, then two minuses 
1 2   // First  one bar, then two bars
+-+--+
| |  |
+-+--+
| |  |
| |  |
+-+--+
------------------
1 0 3 0 2 0
2 1 0 0
+-++---++--++
| ||   ||  ||
| ||   ||  ||
+-++---++--++
| ||   ||  ||
+-++---++--++
+-++---++--++
+-++---++--++
```
Clarifications:
* Input order and format are optional
* Only the boxes should be printed/displayed, but a trailing space or newlines are accepted.
* You may optionally add 1 to all input values if that's more convenient. The second example would then be: `2 3; 2 3`.
This is code golf, so the shortest code in bytes win.
  
[Answer]
# Python 2, 117 Bytes
```
def f(h,v):r="+"+"+".join("-"*i for i in h)+"+\n";print r+r.join(("|"+"|".join(" "*i for i in h)+"|\n")*i for i in v)+r
```
[Try it on ideone.](https://ideone.com/yFGxrK)
Not expecting too much from this. Really simple, just uses python joins and string multiplication to pull everything together.
[Answer]
## JavaScript (ES6), 83 bytes
```
(a,b,g=(a,[s,t])=>t+a.map(n=>s.repeat(n)+t).join``+`
`)=>g(b,[g(a,` |`),g(a,`-+`)])
```
Output includes two trailing newlines.
[Answer]
# [MATL](http://github.com/lmendo/MATL), ~~25~~ ~~22~~ 21 bytes
```
'|-+ '2:"1tiYsQ(]E!+)
```
Uses inputs with `1` added (allowed by the challenge).
[Try it online!](http://matl.tryitonline.net/#code=J3wtKyAnMjoiMXRpWXNRKF1FISsp&input=WzIgMSA0IDEgMyAxXQpbMyAyIDEgMV0)
### Explanation
The code initially builds an array containing `1` for the column indices of non-space characters in the final result, and `0` otherwise. So if the first input is `[2 1 4 1 3 1]` (would be `[1 0 3 0 2 0]` in the 0-based format) this array will be
```
1 0 1 1 0 0 0 1 1 0 0 1 1
```
Note how the length of runs of zeros is related to the input. Specifically, this array is built as follows:
1. Initiallize the array to a single `1`.
2. Compute the cumulative sum of the input and add `1`. In the example this gives `[3 4 8 9 12 13]`.
3. Extend the array from step 1 by assigning `1` to the entries with (1-based) indices given by step 2. Intermediate entries are automatically set to `0`.
A similar array is built for the rows. Second input `[3 2 1 1]` (or `[2 1 0 0 ]`) gives
```
1 0 0 1 0 1 1 1
```
Now the second array is multiplied by `2`, transposed and added with broadcast to the first. This gives the 2D array
```
3 2 3 3 2 2 2 3 3 2 2 3 3
1 0 1 1 0 0 0 1 1 0 0 1 1
1 0 1 1 0 0 0 1 1 0 0 1 1
3 2 3 3 2 2 2 3 3 2 2 3 3
1 0 1 1 0 0 0 1 1 0 0 1 1
3 2 3 3 2 2 2 3 3 2 2 3 3
3 2 3 3 2 2 2 3 3 2 2 3 3
3 2 3 3 2 2 2 3 3 2 2 3 3
```
Indexing into the string `'|-+ '` gives the final result as a 2D char array. Since indexing is modular and 1-based, index `0` corresponds to the last element (space).
```
'|-+ '                   % Push this string
      2:"       ]        % Do this twice
         1               % Push 1 (initial array)
          t              % Push another 1 (contents to be filled in)
           i             % Take input
            Ys           % Cumulative sum
              Q          % Add 1
               (         % Fill 1 into those entries of the array
                 E       % Multiply by 2
                  !      % Transpose
                   +     % Add, with broadcast
                    )    % Index (modular, 1-based) into the string
```
[Answer]
# CJam, 50 Bytes
```
0lS/:i0++:H;lS/:i0+{H{'-*}%'+*N+o{H{S*}%'|*N+o}*}%
```
[Try it online!](http://usandfriends.github.io/CJam101/#code=0lS%2F%3Ai0%2B%2B%3AH%3BlS%2F%3Ai0%2B%7BH%7B%27-*%7D%25%27%2B*N%2Bo%7BH%7BS*%7D%25%27%7C*N%2Bo%7D*%7D%25&input=1%202%0A1%202)
[Answer]
# Pyth, 45 bytes
```
AQj.i*hlH]Js.i*hlG\+m*d\-G-mjb*d]XJ"+-""| "Hk
```
A program that takes input of two comma-separated lists on STDIN and prints the result.
There is probably still some golfing to be done here.
[Try it online](https://pyth.herokuapp.com/?code=AQj.i%2ahlH%5DJs.i%2ahlG%5C%2Bm%2ad%5C-G-mjb%2ad%5DXJ%22%2B-%22%22%7C+%22Hk&test_suite=1&test_suite_input=%5B0%5D%2C%5B0%5D%0A%5B1%2C2%5D%2C%5B1%2C2%5D%0A%5B1%2C0%2C3%2C0%2C2%2C0%5D%2C%5B2%2C1%2C0%2C0%5D&debug=0)
*Explanation coming later*
[Answer]
# Haskell, 55 bytes
```
f[a,b]x=a:do n<-x;(b<$[1..n])++[a]
g x=f[f"+-"x,f"| "x]
```
Defines a function `g` which takes the two input lists and returns a list containing the lines of the output
[Answer]
## PowerShell v2+, 89 bytes
```
param($a,$b)($x="+$(($a|%{'-'*$_})-join'+')+")
$b|%{,"|$(($a|%{' '*$_})-join'|')|"*$_;$x}
```
Dang, don't think I can quite catch JavaScript.
Takes input `$a` and `$b` as explicit arrays. Sets variable `$x` to be the top row of the boxes based on looping through `$a` and some string concatenation. That's encapsulated in parens so it's placed on the pipeline. Then, we loop through `$b`, each iteration putting two strings on the pipeline -- the same style string but with spaces and `|` instead of hyphens and `+`, and `$x`. Those strings are all gathered from the pipeline with an implicit `Write-Output` at program completion, with default newline between them.
### Examples
```
PS C:\Tools\Scripts\golfing> .\make-some-ascii-boxes.ps1 @(0) @(0)
++
++
PS C:\Tools\Scripts\golfing> .\make-some-ascii-boxes.ps1 @(1,0,3,0,2,0) @(2,1,0,0)
+-++---++--++
| ||   ||  ||
| ||   ||  ||
+-++---++--++
| ||   ||  ||
+-++---++--++
+-++---++--++
+-++---++--++
PS C:\Tools\Scripts\golfing> .\make-some-ascii-boxes.ps1 @(1,4,1) @(1,2,1)
+-+----+-+
| |    | |
+-+----+-+
| |    | |
| |    | |
+-+----+-+
| |    | |
+-+----+-+
```
[Answer]
# Ruby, 66 bytes
```
->x,y{d=->c,m,z=x{c+z.map{|w|m*w}*c+c+$/}
d[d[?+,?-],d[?|,' '],y]}
```
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), ~~30~~ 26 [bytes](https://github.com/DennisMitchell/jelly/wiki/Code-page)
```
Ḣị“+-“| ”ị@
1;+\Ṭ
Ç€,€/Ñ€Y
```
Test it at **[TryItOnline](http://jelly.tryitonline.net/#code=4bii4buL4oCcKy3igJx8IOKAneG7i0AKMTsrXOG5rArDh8K14oG5w4cswrUs4oKsL8OR4oKsWQ&input=&args=WzIsMSw0LDEsMywxXQ+WzMsMiwxLDFd)**
How?
The input taken is a list of the two lists, `[vertical, horizontal]`, and uses the incremented option  
- so example 3 takes `[[3,2,1,1], [2,1,4,1,3,1]]`  
Each of these is then converted to a boolean array indicating the rowType or rowCharacterType respectively, e.g. `[[1,0,0,1,0,1,1,1], [1,0,1,1,0,0,0,1,1,0,0,1,1]]`  
The boxes are then constructed by making the rows from the characters identified by the rowType and rowCharacterType combinations - i.e. a rowType identifies either `"+-"` or `"| "` and a rowCharacterType identifies one of those two characters.
```
Ḣị“+-“| ”ị@ - Link 1, create a row: [rowType, [rowCharaterTypes]]
Ḣ           - head - get the rowType
  “+-“| ”   - list of strings ["+-", "| "]
 ị          - index into (if rowType is 1 "+-"; if rowType is 0 "| ")
         ị@ - index into with reversed operands (index into that from rowCharaterTypes)
                (replace each 1 in rowCharaters with "+" or "|" and each 0 with "-" or " ")
1;+\Ṭ - Link 2, create the Type lists from the inputs: int[] nCharacters
1;    - 1 concatenated with the input
  +\  - reduce with addition (accumulation provides the indices)
    Ṭ - boolean array with 1s at those indices
            As an example take the vertical of example 3:
            [3,2,1,1] -> [1,3,2,1,1] -> [1,4,6,7,8] -> [1,0,0,1,0,1,1,1]
            each of which will be passed as a rowType for Link 1
Ç€,€/Ñ€Y - Main link, takes one argument: [Vertical, Horizontal] (incremented option)
Ç€       - call the last link (2) for each of the two lists in the input
  ,€/    - pair each and reduce (making a list of [rowtype [rowCharacterTypes]])
     Ñ€  - call the next link (1) for each
       Y - join on line feeds
```
]