LMLevi Mwendwainlevite.hashnode.dev·Jun 17, 2024 · 2 min readCyclic Sequence PatternUnderstanding Cyclic Sequence Patterns in JavaScript When working with arrays, there are times when you might want to iterate over the elements more than once in a cyclic manner. This means that after reaching the last element of the array, the itera...00
LMLevi Mwendwainlevite.hashnode.dev·Jun 17, 2024 · 1 min readFinding highest contiguous sumdef max_sequence(arr): max = 0 curr = 0 for i in arr: curr +=i if curr < 0: curr=0 if curr > max: max = curr return max00
LMLevi Mwendwainlevite.hashnode.dev·Apr 25, 2024 · 1 min readObject Parameter DestructuringToday I've learnt about object parameter destructuring and I'm surprised I never knew about it till today. Its where you destructure an object into a function by directly entering the key within curly brackets. Normal destructuring uses the normal fo...00
LMLevi Mwendwainlevite.hashnode.dev·Apr 25, 2024 · 3 min readList Rendering in React JsRendering JSX elements stored in variables I have been studying React Js this past week and it has been surprisingly quite simple (so far) but one if my key takeaways from today's content has been how you can render JSX elements that have been stored...00
LMLevi Mwendwainlevite.hashnode.dev·Apr 13, 2024 · 4 min readJavaScript Event ListenersWorking with event listeners For the past week I've been working on my final school project and something that had been a bit of a challenge for me ended up being event listeners. Over the course of a few assignments that I had been doing, I simply d...00