sulea Posted June 15, 2011 Report Share Posted June 15, 2011 (edited) se da un text,codurile ascii ale literelor se memoreaza intr-un vector V;se da o cheie de criptare (sa spunem un nr intre 1 si 255)function criptfor i de la 1 la length_text v=v*cheie for j de la i la length_text inc cheie v[j]=v[j]+cheie+j end forend forv[i+1]=(cheie+15+3*i+3*2-1*3)+vend functioncare a fost textul initial care s-a criptat si ce cheie s-a folosit, daca avem urmatorul output in vectorul v:16010 40043 70308 106877 155434 191991 268502 335265 410798 491027 572045 658650 748718 846627 939031 1033322 1033662trimiteti raspunsurile prin pm.poate dau si cate un log user/parole castigatorilor.primul care rezolva challengeul este em. felicitariantrax200 si staticwater au rezolvat corect!! Edited July 4, 2011 by sulea Quote Link to comment Share on other sites More sharing options...
Patrunjel Posted June 15, 2011 Report Share Posted June 15, 2011 (edited) Misto challenge, fix acuma l-am vazut si pe primul.Intrebare : ce pula mea inseamna "inc cheie" ? (1-255, ipv4 te-a marcat pe viata )*primul element din V e la 0 sau la 1? Edited June 15, 2011 by Patrunjel Quote Link to comment Share on other sites More sharing options...
sulea Posted June 15, 2011 Author Report Share Posted June 15, 2011 inc cheie inseamna cheie=cheie+1 (adica se incrementeaza cu 1)vector = [x,y,z]pozitie = 1,2,3length = 3succes! Quote Link to comment Share on other sites More sharing options...
Patrunjel Posted June 15, 2011 Report Share Posted June 15, 2011 (edited) Sigur acolo vroiai sa pui v[i+1]=(cheie+15+3*i+3*2-1*3)+v[i] ?Ai iesit din for cu i=nr_el, deci degeaba e i, si oricum nu faci nimic, ca faci referire la i+1.Oricum, nu asta era ideea, vroiam doar sa-ti atrag atentia, sa te uiti peste linia aia si sa spui daca ala e sigur locul ei.*Codul in C++, pentru cei care nu stiu Pascal (sau ce-o fi acolo)*for(i=1; i<=lung; ++i){ v[i]*=cheie; for(j=i; j<=lung; ++j){ ++cheie; c[j]=c[j]+cheie+j; }}v[i+1]=(cheie+15+3*i+3*2-1*3)+v[i]; Edited June 15, 2011 by Patrunjel Quote Link to comment Share on other sites More sharing options...
em Posted June 15, 2011 Report Share Posted June 15, 2011 Ai pm. De data asta macar a fost un raspuns mai uman 1 Quote Link to comment Share on other sites More sharing options...
antrax200 Posted July 1, 2011 Report Share Posted July 1, 2011 Ai pm . "Niciodata sa nu-i atribui unei persoane rautatea atunci cand exista prostia" Quote Link to comment Share on other sites More sharing options...
staticwater Posted July 2, 2011 Report Share Posted July 2, 2011 Ai pm. Nu e greu dar nici usor! Quote Link to comment Share on other sites More sharing options...