Cum ar arăta viaţa mea descrisă în câteva linii de cod :
init Life(); // $dead=FALSE; $money=0; $health=100;
$Andrei= give_birth(‘Andrei’);
$liking_school=0;
while (!$dead)
{
$day++;
$year=intval($day/365);
if ($year>=7) go_to_school($Andrei);
if ($liking_school>0) $Andrei[‘happy’]++;
else
{
$Andrei[‘happy’]= -10;
$Andrei[‘sad’]++;
scream(„WAAAAAAAAAH !!„);
while (!present($Andrei[$mother])) cry();
}
$bani_pachet=$_GET[‘bani_pachet’];
if (repetent($Andrei))
{
$nr_ani_repetati++;
$an_scolar=$year-7-$nr_ani_repetati;
}
else $an_scolar=$year-7;
$money+=$bani_pachet;
if (current_position($Andrei)==”Electric Shop”) $money- -;
if (($an_scolar==8) and ($liking_school==0))
{
$Andrei[‘stres’]++;
$Andrei[$mother][‘stres’]=100*$Andrei[‘stres’];
}
if (exam_scuccess(capacitate(), $Andrei))
{
$nota_capacitate=capacitate(GET,’nota’);
print $nota_capacitate; // returns 9.18
if ($nota_capacitate >= 5) $Andrei[‘happy’]++;
if ($nota_capacitate >= 9,5) $Andrei[$mother][‘happy’]++; else init crize();
init Liceu();
}
else ratat($Andrei);
set coleg_de_banca($Andrei, $Dani);
while (coleg_de_banca($Andrei)==$Dani)
{
$medie_liceu++;
$Andrei[$diriginta][‘happy’]++;
}
meet($Andrei, $George);
set coleg_de_banca($Andrei, $George);
$medie_liceu=$medie_liceu-2;
$Andrei[‘happy’]=sqr($Andrei[‘happy’]);
$Andrei[$diriginta][‘happy’]= – 9.9999999e+36;
if ($medie_liceu>=5) $an_liceu++;
if ($an_liceu==3) init majorate();
meet ($Andrei, $alcool);
meet ($Andrei, $tutun);
$health- -;
if ($an_liceu==4)
{
$Andrei[‘stres’]=0;
$alcool++;
$tutun++;
$health- -;
$Andrei[$mother][‘stres’]= 9.9999999e+36;
while (!learn($Andrei)) crize();
}
if (exam_success(bac(),$Andrei))
{
$nota_bac=bac(GET,’nota’);
print $nota_bac; //returns 9.34
if ($nota_bac >= 5) $Andrei[‘happy’]++;
$Andrei[$mother][‘happy’]=$Andrei[‘happy’];
init Facultate();
}
else
{
crize();
init repeat_bac();
$Andrei[‘happy’]=0;
$Andrei[$mother][‘happy’]= – 9.9999999e+36;
}
meet($Andrei, $Danutz);
$alcool= pow($alcool, 3);
$tutun++;
$health- -;
$money- -;
$day_of_week=get_day($current_date,’d’);
if ($day_of_week==’Friday’)
{
init Club();
$money- -;
$alcool++;
$tutun++;
$health- -;
}
if ($money==0) call($Andrei[$mother]);
init Serviciu();
if (day_of_month($current_date)==1)
{
$money=$money+Serviciu($salariu);
$Andrei[‘happy’]++;
}
if (current_position($Andrei)==”IT Shop”) $money=0;
if ($health==’0′) $dead=1; // GAME OVER
}