Skip to content

Baraah A.#5

Open
thebaraah wants to merge 1 commit intoHackYourAssignment:mainfrom
thebaraah:main
Open

Baraah A.#5
thebaraah wants to merge 1 commit intoHackYourAssignment:mainfrom
thebaraah:main

Conversation

@thebaraah
Copy link

No description provided.

@sycons sycons self-assigned this Feb 14, 2026
Copy link

@sycons sycons left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These were properly implemented.

  • Count values above a threshold ✅
  • Debug and Fix the Logic ✅

I've provided feedback on the other tasks. The task wasn't configured to run the tests that were written and binarySearch was not called.

@@ -0,0 +1,33 @@
import {describe , it , expect} from "vitest";
import {calculateAverage} from "./calculateAverage";
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Node is unable to find resolve this import because there are two files that are named calculateAverage minus the file extension.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am unable to run the test suite because package.json is missing. This task should be also configured to install the package vitest and have a script that runs the tests.

More info: https://vitest.dev/guide/#adding-vitest-to-your-project

console.time("linear search 100k");
linearSearch(array2, target);
console.timeEnd("linear search 100k");

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Linear search for 1M is missing.

console.timeEnd("linear search 10m");

console.time("binary search 1k");
linearSearch(array1, target);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should call the function binarySearch. Also have a look at the code below this.

@sycons sycons added Reviewed This assignment has been reivewed by a mentor and a feedback has been provided and removed To review labels Feb 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Reviewed This assignment has been reivewed by a mentor and a feedback has been provided

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants