Problem 32E

a) Give a recursive definition of the function ones(s),which counts the number of ones in a bit string s.

b) Use structural induction to prove that ones(st) = ones(s) + ones(t).

Lecture Feb 27 Chapter 42 Circulation and Gas Exchange Animal Diversity 1 is lab this week Circulartory systems link exchange surfaces w cells thruout body -small molecules can move by diffusion, its allowing exchange between cells -diffusion is only efficient over small distances bc the time it takes for diffusion must be proportional to the square of the distance -so, diffusion effiecncy is low bc the distance is small 2 kinds of circulatory systems; open and closed -both systems have 3 basic componenets; 1;circulatory fluid (blood or hemolymph) 2;set of tubes (blood vessels) 3;muscular pump (heart) -in insects, hemolypmh bathes the organs directly in an open circulatory system, hemolymphs bathes the organs directly -closed circulatory system, blood is