protected String buildSolution() { StringBuilder s = new StringBuilder(4000); s.AppendFormat(nd.SelectSingleNode("Soln").InnerText); s.Replace("Travel_Speed", Travel_Speed.ToString()); s.Replace("Dist_Loc1", Dist_Loc1.ToString()); s.Replace("Dist_Loc2", Dist_Loc2.ToString()); s.Replace("Time_Taken", Time_Taken.ToString()); s.Replace("Distance_Traveled", Distance_Traveled.ToString()); return(s.ToString()); }
protected override String createQuestion() { string s; s = createQns(); //questionPrototype.ElementAt(QnsNo); StringBuilder question = new StringBuilder(s); Travel_Speed = generateTravel_Speed(); Time_Taken = generateTime_Taken(); Distance_Traveled = CalculateDistance_Traveled(); Dist_Loc1 = generateDist_Loc1(); Dist_Loc2 = CalculateDist_Loc2(); question.Replace("Travel_Speed", Travel_Speed.ToString()); question.Replace("Dist_Loc1", Dist_Loc1.ToString()); question.Replace("Dist_Loc2", Dist_Loc2.ToString()); question.Replace("Time_Taken", Time_Taken.ToString()); question.Replace("Distance_Traveled", Distance_Traveled.ToString()); return(question.ToString()); }