ring r=0,(x,y,z),lp;
int a=12345;
poly f=10;
ideal i=x,y;
module m=x*gen(1),y*gen(2);
list l=f,i;
intvec iv=1,2,3,45,5,6,7,8;
timer=1;
string s="sdgjgdksdgjs";
proc myprintmat(matrix m){
  print(m);
}
proc stringproc1(){
    return("blubber");
}
proc listproc1(list l){
    print(l);
    list erg=1,list(2,2784);
    return(erg);
}
proc testproc1(){
print("Hallo Welt");
return(1);
}
proc testproc2(poly p){
print("Hallo Welt");
print(p*p);
return(p*p+p*p*p);
}
proc testproc3(vector p){
print("Hallo Welt ihr Vektoren");
print(p);
return(p);
}
proc testproc4(number p){
print("Hallo Welt ihr Numbers");
print(p);
return(p);
}

proc testproc5(int p){
print("Hallo Welt ihr ints");
print(p);
return(p);
}
proc testproc6(poly p, poly q){
  matrix m[3][10];
  int i;
  int j;
  for(i=1;i<=3;i++){
    for(j=1;j<=10;j++){
	m[i,j]=p^i*q^j;
    }
  }

  return(m);
}

proc testproc7(module p){
print("Hallo Welt ihr Modules");
print(p);
return(p);
}
proc testproc8(intvec iv){
    print("Hallo Welt ihr Intvecs");
    print(iv);
    return(iv);
}

list mylist=1,2,3;
LIB("python_module.so");
Python_module::python("from Singular import *

from interpreter import *
functions=SingularGlobalsProxy()
functions.setring(functions.r)
print functions.mylist;
functions.mylist=[1,2,[5,6]]
print functions.mylist
print functions.s
functions.s='only a example'
print functions.s
functions.__getattr__('print')('Python ist fun und fun und fun')
print functions.f
print functions.i
firstl=functions.l
print firstl
print functions.listproc1([1,[3,6]])
print functions.stringproc1()
for i in firstl:
    print i

x=functions.var(1)
y=functions.var(2)
i=Ideal()
i.append(x)
i.append(x+y)
print i
print functions.groebner(i);
#print functions.std(i);
xy=x*y
functions.f=xy

xye1=xy*gen(1)

print functions.testproc2(xy)
print functions.testproc3(xye1)
print functions.testproc4(Number(3243287))
print functions.testproc5(325)
print functions.testproc6(x,y)
print functions.testproc7(functions.m)
print functions.testproc8(tuple(range(10)))
from Singular import foo2;
m=functions.testproc6(x,y)
functions.myprintmat(m)
print functions.a
print 'Read module:', functions.m

print i
print 'suc1'
print i
print functions.std(i)
print functions.random(1,10)
print 'hallo'
print functions.intersect(i,i,i,i)

v=IntVector()
v.append(12)
v.append(13)
print len(v)
print v

print 'calling print'
functions.__getattr__('print')(Ring());
print 'the end'
print functions.ringlist(Ring())
print functions.iv
functions.iv=v
print functions.iv
");
print(f);

$
