Skip to content

Commit 967f8f6

Browse files
author
Gonzalo Diaz
committed
[REFACTOR] [Hacker Rank] Interview Preparation Kit: String Manipulation: Sherlock and the Valid String.
* Adjusted the interface to match what hackerrank expects.
1 parent e3fe04e commit 967f8f6

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/hackerrank/interview_preparation_kit/string_manipulation/sherlock_and_valid_string.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
const __YES__ = 'YES';
66
const __NO__ = 'NO';
77

8-
export function isValidCompute(s: string): boolean {
8+
function isValidCompute(s: string): boolean {
99
if (s.length <= 1) {
1010
return true;
1111
}
@@ -48,8 +48,9 @@ export function isValidCompute(s: string): boolean {
4848
return false;
4949
}
5050

51-
export function isValid(s: string): string {
51+
function isValid(s: string): string {
5252
return isValidCompute(s) ? __YES__ : __NO__;
5353
}
5454

5555
export default { isValid };
56+
export { isValid };

0 commit comments

Comments
 (0)