fix(learn): Consolidated comments for Coding Interview Prep challenges - part 2 of 2 (#39576)
* fix: consolidate comments for use with the translation dictionary * fix: added blank line between comments Co-authored-by: Tom <20648924+moT01@users.noreply.github.com> * fix: removed unneeded comment Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
This commit is contained in:
@ -132,8 +132,6 @@ function replaceChar(origString, replaceChar, index) {
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
|
||||
function solve24(numStr) {
|
||||
const digitsArr = numStr.split('');
|
||||
const answers = [];
|
||||
|
@ -64,7 +64,6 @@ function emirps(n) {
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function emirps(num, showEmirps)
|
||||
{
|
||||
const is_prime = function(n)
|
||||
|
@ -65,7 +65,6 @@ function primeGenerator(num, showPrimes) {
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function primeGenerator(num, showPrimes) {
|
||||
let i,
|
||||
arr = [];
|
||||
|
@ -50,7 +50,6 @@ tests:
|
||||
<div id='js-seed'>
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function hailstoneSequence() {
|
||||
const res = [];
|
||||
|
||||
@ -78,7 +77,6 @@ const res = [[27, 82, 41, 124, 8, 4, 2, 1], [351, 77031]];
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function hailstoneSequence () {
|
||||
const res = [];
|
||||
|
||||
|
@ -43,7 +43,7 @@ function isHarshadOrNiven() {
|
||||
firstTwenty: [],
|
||||
firstOver1000: undefined
|
||||
};
|
||||
// Change after this line
|
||||
// Only change code below this line
|
||||
|
||||
return res;
|
||||
}
|
||||
|
@ -50,7 +50,6 @@ tests:
|
||||
<div id='js-seed'>
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function heronianTriangle(n) {
|
||||
|
||||
|
||||
@ -84,7 +83,6 @@ const res = [
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function heronianTriangle(n) {
|
||||
const list = [];
|
||||
const result = [];
|
||||
|
@ -71,7 +71,6 @@ tests:
|
||||
<div id='js-seed'>
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function ffr(n) {
|
||||
return n;
|
||||
}
|
||||
@ -102,7 +101,6 @@ const ffsParamRes = [[10, 14], [50, 59], [100, 112], [1000, 1041]];
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
const R = [null, 1];
|
||||
const S = [null, 2];
|
||||
|
||||
|
@ -51,7 +51,6 @@ tests:
|
||||
<div id='js-seed'>
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function splitCoconuts(intSailors) {
|
||||
|
||||
return true;
|
||||
@ -69,7 +68,6 @@ function splitCoconuts(intSailors) {
|
||||
|
||||
|
||||
```js
|
||||
// noprotect
|
||||
function splitCoconuts(intSailors) {
|
||||
let intNuts = intSailors;
|
||||
let result = splitCoconutsHelper(intNuts, intSailors);
|
||||
|
Reference in New Issue
Block a user