Algorithms

Spring 2011
course
navigation

Apr 14

random

1. sorting algorithms as dances
2. Bug in my strmap.c in code/hash_table_2 (now fixed) from last time:
// collisions++ // WRONG; need to increment by number of things in bucket - 1 collisions += bucket->count - 1;

crypto

Go over the material in my notes from last time.
But how can we possibly find (a**b mod c) when a, b, c are a hundred digits long? Answer: see attached; try (10, 1000, 501) and compare with python's result.
http://cs.marlboro.edu/ courses/ spring2011/algorithms/ notes/ Apr_14
last modified Thursday April 14 2011 1:05 am EDT

attachments [paper clip]

     name last modified size
[COD]powmod.c Apr 14 2011 1:05 am 831B