

Generic Sky Box
Finish the generic class Box<T>:
getValue()returns the value the box was created with.map(fn)takes a function fromTtoUand returns a newBox<U>holdingfn(value). The original box must not change.
Then write boxPipeline(start): put start in a box, map it with "add 1", then map the result with "double it", and return the final value.
Examples
boxPipeline(3)
→ 8
boxPipeline(0)
→ 2
solution.ts
TYPESCRIPT
Saved as you type
Tests
0 of 4 passing- •boxPipeline(3)boxPipeline(3)expected 8
- •boxPipeline(0)boxPipeline(0)expected 2
- •boxPipeline(-1)boxPipeline(-1)expected 0
- •boxPipeline(10)boxPipeline(10)expected 22
On the line
+60 XP
Pass all 4 tests to claim it.
