Program keygeneratorezpix ; uses crt ; var serialnumber,last : string ; i,sn,panjang : integer ; function getvalue(un : string) : integer ; var j,serial : integer ; begin serial:=0 ; for j:=1 to length(un) do serial:=serial + (ord(un[j]) * (j+3)) ; getvalue:=serial ; end ; begin clrscr ; writeln('Key-Generator Ez-Pix 1.1') ; writeln('Visit our page at http://all.at/ekh') ; writeln('Type your username, remember they must be :') ; textcolor(lightred) ; writeln('* At least 2 char, and all in lowercase !!! * ') ; normvideo ; writeln('Enter now : ') ; readln(serialnumber) ; for i:=1 to length(serialnumber) do begin if (ord(serialnumber[i])<97) and (ord(serialnumber[i])>65) then begin writeln('I told you to enter all in lowercase !!!') ; halt ; end ; end ; if length(serialnumber) < 2 then halt ; panjang:=length(serialnumber) - 1 ; last:=upcase(serialnumber[panjang]) ; serialnumber:='N'+serialnumber+'1972' ; sn:=getvalue(serialnumber) ; sn:=((sn div 3) + 1710) mod 1000000 ; str(sn,serialnumber) ; serialnumber:='EZP1 '+serialnumber ; sn:=getvalue(serialnumber) ; sn:=(sn div 7) mod 100 ; serialnumber[5] := '9' ; serialnumber[6] := '9' ; writeln('Your registration key is : ',serialnumber,sn,panjang,last) ; end.