Skip to content

Latest commit

 

History

History
31 lines (18 loc) · 1.34 KB

README.md

File metadata and controls

31 lines (18 loc) · 1.34 KB

KaprekarCount

What is this?

I have no idea, i am very confused and can not think properly as of next week i have the first 4 exams that will determine my future and i still did not study, now its 5:42 AM and i still did not sleep because of my anxiety so i ended up doing nothing the whole day except Djing and programming.

Why Kaprekar?

I was laying in bad and scrolling through reddit on the sub r/TikTokCringe and stumbled on this video, while watching it i was thinking on what i can do with what i just learned if i programmed it (professional deformation).

Techno & Coding

So i also uploaded my live set from today on SoundCloud if you want to listen to it.

How to use this class?

Do you really have to? If yes then quick example:

const KaprekarCount = require('../index');
const Kaprekar = new KaprekarCount();
const cycle = Kaprekar.cycle(2342);
const count = Kaprekar.cycleCount(2342);
console.log(cycle); // will log the array with the numbers of the cycle
console.log(count); // literally the length of the array lol