*** empty log message ***
[chuck-blob.git] / exile / bio.ck
blobb58296c044e2799064c9f0d61b7b980ac8a74b03
1 public class human
3     8 => float weight;
4     0 => int degrees;   
6     Event Birthday;
8     fun void life()
9     {
10         while(true)
11         {
12             dur => now;
13             Adam_Tindale.Birthday.signal();
14             Adam_Tindale.weight() * 1.5 => Adam_Tindale.weight;
15         }
16     }
19 class male extends human
21     public time born(){
22         return now;
23     }
24     // fun int study(string school){
25     //     return degrees++;
26     // }
27     fun string study(string school, string program, int level, int completed){
28         degrees++;
29         if (level == 0)
30             return "Undergraduate Degree";
31         if (level == 1)
32             return "Masters Degree";
33         if (level == 2)
34             return "Doctor of Philosophy";
35     }
36     fun void party(Event e){
37         while(true){
38             e => now;
39             if ( now % 10::year != 0)
40                 <<<"It is your Birthday!!!!">>>;
41             else
42                 <<<"No, it isn't my birthday...">>>;
43         }
44     }
47 male Adam_Tindale;
49 Adam_Tindale.born() => time birth;
50 spork ~ life() => Shred lifetime;
52 Adam_Tindale.study("LougboroughPublicSchool");
53 Adam_Tindale.study("BayridgePublicSchool");
54 Adam_Tindale.study("BayridgeSecondarySchool");
55 Adam_Tindale.study("FrontenacSecondarySchool"); 
56 <<< "Public Schools Attended: ",degrees >>>;
58 <<< Adam_Tindale.study("QueensUnivsersity","MusicPerformance",0,true) >>>;      
59 <<< Adam_Tindale.study("McGillUniversity","MusicTechnology",1,true) >>>;
60 // still working on this one
61 <<< 
62 Adam_Tindale.study("UnivsersityOfVictoria","InterdisciplinaryStudies",2,false) 
63 >>>;
65 spork ~ party(Adam_Tindale.birthday);
67 //born 1978/05/10
68 //today 2005/09/30
69 27::year + 4::month + 20::day => now;
71 //you never know...
72 ( birth + std.rand2f(0., 80.) )::year => time death;
74 //it is going to happen!
75 death => now;
76 machine.remove( lifetime.id() );
77 me.exit();