I tried the following but it didn't work,

a, x= var('a,x');
p = x^2 - 7*a*x + 5;
a=5;
m = max((p == 0).solve([x]))
m

1 | initial version |

I tried the following but it didn't work,

a, x= var('a,x');
p = x^2 - 7*a*x + 5;
a=5;
m = max((p == 0).solve([x]))
m

2 | No.2 Revision |

I tried the following but it didn't work,

~~a, ~~x= ~~var('a,x');
~~var('x');
p = x^2 - 7*a*x + 5;
a=5;
m = max((p == ~~0).solve([x]))
m~~0).solve([x]))

3 | No.3 Revision |

I tried the following but it didn't work,

~~x= var('x');
~~p = x^2 - 7*a*x + 5;
a=5;
m = max((p == 0).solve([x]))

Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.