[BACK]Return to program CVS log [TXT][DIR] Up to [local] / OpenXM_contrib / pari / src / test / in

Annotation of OpenXM_contrib/pari/src/test/in/program, Revision 1.1.1.1

1.1       maekawa     1: \p 38
                      2: \e
                      3: alias(ln,log)
                      4: ln(2)
                      5: for(x=1,5,print(x!))
                      6: fordiv(10,x,print(x))
                      7: forprime(p=1,30,print(p))
                      8: forstep(x=0,Pi,Pi/12,print(sin(x)))
                      9: forvec(x=[[1,3],[-2,2]],print1([x[1],x[2]]," "));print(" ");
                     10: getheap
                     11: getrand
                     12: getstack
                     13: if(3<2,print("bof"),print("ok"));
                     14: kill(y);print(x+y);reorder([x,y]);print(x+y);
                     15: f(u)=u+1;
                     16: print(f(5));kill(f);
                     17: f=12
                     18: g(u)=if(u,,return(17));u+2
                     19: g(2)
                     20: g(0)
                     21: setrand(10)
                     22: n=33;until(n==1,print1(n," ");if(n%2,n=3*n+1,n=n/2));print(1)
                     23: m=5;while(m<20,print1(m," ");m=m+1);print()
                     24: \\
                     25: default(realprecision,28)
                     26: default(seriesprecision,12)
                     27: print((x-12*y)/(y+13*x));
                     28: print([1,2;3,4])
                     29: print1(x+y);print(x+y);
                     30: print((x-12*y)/(y+13*x));
                     31: print([1,2;3,4])
                     32: print1(x+y);print1(" equals ");print(x+y);
                     33: print1("give a value for s? ");s=input();print(1/(s^2+1))
                     34: printtex((x+y)^3/(x-y)^2)
                     35: for(i=1,100,for(j=1,25,if(i+j==32,break(2)));print(i))
                     36: {
                     37:   u=v=p=q=1;
                     38:   for (k=1,400,
                     39:     w=u+v; u=v; v=w;
                     40:     p *= w; q=lcm(q,w);
                     41:     if (k%50==0,
                     42:       print(k" "log(p)/log(q))
                     43:     )
                     44:   );
                     45: }
                     46: /* added in 1.924.13 */
                     47: install(addii,GG)
                     48: addii(1,2)
                     49: kill(addii)
                     50: /* up to here */
                     51: getheap
                     52: print("Total time spent: ",gettime);
                     53: \q

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>