feat(interview-prep): Updated descriptions and corrected syntax

This commit is contained in:
Bhanu Pratap Singh
2020-02-18 21:57:24 +05:30
committed by Kristofer Koishigawa
parent e4a6f5563f
commit ec0a5e0b6f
5 changed files with 20 additions and 18 deletions

View File

@@ -6,7 +6,7 @@ challengeType: 5
## Description
<section id='description'>
You are given a string and your task is to calculate frequency of each character.
Given a string, calculate the frequency of each character.
All characters should be counted. This includes lower and upper case letters, digits, whitespace, special characters, or any other distinct characters.
</section>
@@ -48,7 +48,7 @@ tests:
<div id='js-seed'>
```js
function letterFrequency (txt) {
function letterFrequency(txt) {
// Good luck!
}
```
@@ -61,7 +61,7 @@ function letterFrequency (txt) {
<section id='solution'>
```js
function letterFrequency (txt) {
function letterFrequency(txt) {
var cs = txt.split(''),
i = cs.length,
dct = {},