Skip to content

Latest commit

 

History

History
15 lines (10 loc) · 1.42 KB

File metadata and controls

15 lines (10 loc) · 1.42 KB

Sum extreme #math #template-literal

by null @uid11

Take the Challenge

Implement a type Sum<A, B> that summing two non-negative integers and returns the sum as a string. Numbers can be specified as a string, number, or bigint.

For example,

type T0 = Sum<2, 3> // '5'
type T1 = Sum<'13', '21'> // '34'
type T2 = Sum<'328', 7> // '335'
type T3 = Sum<1_000_000_000_000n, '123'> // '1000000000123'

Back Share your Solutions Check out Solutions