Skip to content

Abdullah Mishari and Ahmad Alazmi#6

Open
AbdullahM25 wants to merge 1 commit intoJoinCODED:mainfrom
AbdullahM25:main
Open

Abdullah Mishari and Ahmad Alazmi#6
AbdullahM25 wants to merge 1 commit intoJoinCODED:mainfrom
AbdullahM25:main

Conversation

@AbdullahM25
Copy link

No description provided.

// Your code here

return false; // replace false with what you see is fit
return n % 2 !== 0 ? true : false;

Choose a reason for hiding this comment

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

You can also just do:

function isOdd(n: number): boolean {
    return n%2 !== 0;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants