kokulife: screenie of ichigo and otome from aikatsu, hugging (Default)

NPRG062 (Introduction to algorithms) [lecture] - recursion, see also: today's daily message, including the classic example of the fibonacci sequence, how to deal with unnecessary calculation of the same things by using caching or by building from the bottom up and the best way to do it, which uses matrices, you raise the matrix ((0,1),(1,1)) to the nth power and then multiply by the vector (f0,f1), you can use the quick raising to the power by using the binary representation of n, gosh this is a long entry, we also did recursive generation, like how to break up a number into all the sums it can be made of


NPRG030 (Programming 1) [lecture] - int("number") isn't actually a function, it's a constructor! most of the class was focused on working with files, things i know and we did during the tutorial previously.. also the way strings are interpreted in memory (they terminate at a specific char, like c strings) and the walrus operator := which has a silly name methinks




koku daily message:
recursion, see also: recursion

March 2026

S M T W T F S
1234567
89 1011121314
15161718192021
22232425262728
293031    

Syndicate

RSS Atom

Most Popular Tags

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated Apr. 7th, 2026 03:23 pm
Powered by Dreamwidth Studios