I have the following query
maple('G :=factor(x^2-5*x+6)')
ans =
G := (x-2)*(x-3)
How can the first brackets be assigned by programming to G1 and second brackets to G2 such that G=G1*G2 i.e getting the ans
G1 := (x-2)
G2 := (x-3)
Within Maple you could could use the first and second operands of G...
G :=factor(x^2-5*x+6);
G1 := op(1,G);
G2 := op(2,G);