Back to Type Challenges

README

questions/27958-medium-checkrepeatedtuple/README.md

latest1.4 KB
Original Source
<!--info-header-start--><h1>CheckRepeatedTuple </h1><blockquote><p>by bowen <a href="https://github.com/jiaowoxiaobala" target="_blank">@jiaowoxiaobala</a></p></blockquote><p><a href="https://tsch.js.org/27958/play" target="_blank"></a> &nbsp;&nbsp;&nbsp;<a href="./README.zh-CN.md" target="_blank"></a> </p><!--info-header-end-->

Implement type CheckRepeatedChars<T> which will return whether type T contains duplicated member

For example:

ts
type CheckRepeatedTuple<[1, 2, 3]>   // false
type CheckRepeatedTuple<[1, 2, 1]>   // true
<!--info-footer-start-->

<a href="../../README.md" target="_blank"></a> <a href="https://tsch.js.org/27958/answer" target="_blank"></a> <a href="https://tsch.js.org/27958/solutions" target="_blank"></a> <!--info-footer-end-->