document.write( "Question 73899: If Mary was 5 times older than Mark 10 years ago and will be twice his age in 20 years. How old are they now?\r
\n" ); document.write( "\n" ); document.write( "I don't know how to put this into functions. Can you help me please
\n" ); document.write( "

Algebra.Com's Answer #52913 by ankor@dixie-net.com(22740)\"\" \"About 
You can put this solution on YOUR website!
Write an equation for each phrase; My = Mary's age now; Mk = Marks age now
\n" ); document.write( ":
\n" ); document.write( "If Mary was 5 times older than Mark 10 years ago
\n" ); document.write( "(My - 10) = 5(Mk-10)
\n" ); document.write( ":
\n" ); document.write( "and will be twice his age in 20 years.
\n" ); document.write( "(My + 20) = 2(Mk + 20)
\n" ); document.write( ";
\n" ); document.write( "How old are they now?
\n" ); document.write( "Using the 1st equation:
\n" ); document.write( "My - 10 = 5(Mk -10)
\n" ); document.write( "My - 10 = 5Mk - 50
\n" ); document.write( "My = 5Mk - 50 + 10
\n" ); document.write( "My = (5Mk - 40)
\n" ); document.write( ":
\n" ); document.write( "Substitute (5Mk-40) for My in the 2nd equation:
\n" ); document.write( "My + 20 = 2(Mk + 20)
\n" ); document.write( "(5Mk - 40) + 20 = 2Mk + 40
\n" ); document.write( "5Mk - 20 = 2Mk + 40
\n" ); document.write( "5Mk - 2Mk = 20 + 40
\n" ); document.write( "3Mk = 60
\n" ); document.write( "Mk = 60/3
\n" ); document.write( "Mk = 20 yrs is Marks present age
\n" ); document.write( ":
\n" ); document.write( "Find Mary's age using the 1st equation as rearranged to:
\n" ); document.write( "My = 5Mk - 40
\n" ); document.write( "My = 5(20) - 40
\n" ); document.write( "My = 100 - 40
\n" ); document.write( "My = 60 yrs is Mary's present age
\n" ); document.write( ":
\n" ); document.write( "Check our solution by substitution in the 2nd equation:
\n" ); document.write( "60 + 20 = 2(20 + 20)
\n" ); document.write( "80 = 80 proves our solutions
\n" ); document.write( ":
\n" ); document.write( "Did this make sense to you?\r
\n" ); document.write( "
\n" ); document.write( "\n" ); document.write( "
\n" ); document.write( "
\n" );