Posted on: 12/15/2014 12:43:20 PM | Views : 444

I am changing the complexity of a Question low to moderate when answer is right  and then moderate to high similarly for wrong i change its Complexity level high to low  and if one level of complexity not found change the complexity level  here i have done it but i need less code to do this \
Here Is my Code plz help to make it less
if (getoption == adq.CorrectAnswer) {
if (complevel == 1) { complevel++; if (k <= qlist2.Count() - 1) { int qno = qlist2[k]; adq = db.AddQuestions.Single(x => x.AddQuestionID == qno); List<Option> opt = db.Options.Where(op => op.AddQuestionID == adq.AddQuestionID).ToList(); vm.Questions = adq; vm.Options = opt; vm.UserName = uName; } else if (l <= qlist3.Count() - 1) { complevel++; int qno = qlist3[l]; adq = db.AddQuestions.Single(x => x.AddQuestionID ...

Go to the complete details ...