blob: 3fae916b0f7ec84a115ba17256bd2a6f89e34651 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
// Tests space.comb()
space = require('../space');
newspace = new space.Space();
newspace.adhoc('\
line1\n\
&&&&transparency&&&&\n\
\n\
afterempty\n')
otherspace = new space.Space();
otherspace.adhoc('\
&&&transparency&&&\n\
testline');
function add(char1,char2){
if (char1 == '') return char2;
else return char1;
}
otherspace.comb(newspace, add, [0,0]);
console.log(otherspace.print());
|