public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            int extraPoint = 0;

            if (IsWeighted)
            {
                if (studentType.Equals(StudentType.DualEnrolled) || studentType.Equals(StudentType.Honors))
                {
                    extraPoint = 1;
                }
            }

            switch (letterGrade)
            {
            case 'A':
                return(4 + extraPoint);

            case 'B':
                return(3 + extraPoint);

            case 'C':
                return(2 + extraPoint);

            case 'D':
                return(1 + extraPoint);

            case 'F':
                return(0 + extraPoint);
            }
            return(0 + extraPoint);
        }
Exemple #2
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            double result = 0;

            switch (letterGrade)
            {
            case 'A':
                result = 4;
                break;

            case 'B':
                result = 3;
                break;

            case 'C':
                result = 2;
                break;

            case 'D':
                result = 1;
                break;

            case 'F':
                result = 0;
                break;
            }
            if (IsWeighted && (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled)))
            {
                result += 1;
            }

            return(result);
        }
Exemple #3
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            int grade = 0;

            switch (letterGrade)
            {
            case 'A':
                grade = 4;
                break;

            case 'B':
                grade = 3;
                break;

            case 'C':
                grade = 2;
                break;

            case 'D':
                grade = 1;
                break;

            case 'F':
                grade = 0;
                break;
            }

            if (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled))
            {
                grade += 1;
            }
            return(grade);
        }
Exemple #4
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            double gpa = 0;

            switch (letterGrade)
            {
            case 'A':
                gpa = 4;
                break;

            case 'B':
                gpa = 3;
                break;

            case 'C':
                gpa = 2;
                break;

            case 'D':
                gpa = 1;
                break;

            case 'F':
                gpa = 0;
                break;
            }
            if (IsWeighted && (studentType.Equals(StudentType.DualEnrolled) || studentType.Equals(StudentType.Honors)))
            {
                gpa += 1;
            }
            return(gpa);
        }
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            var modifier = 0;

            if (IsWeighted &&
                (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled)))
            {
                modifier = 1;
            }

            switch (letterGrade)
            {
            case 'A':
                return(4 + modifier);

            case 'B':
                return(3 + modifier);

            case 'C':
                return(2);

            case 'D':
                return(1);
            }
            return(0);
        }
Exemple #6
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            var additonal = 0;

            if (IsWeighted && (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled)))
            {
                additonal = 1;
            }
            switch (letterGrade)
            {
            case 'A':
                return(4 + additonal);

            case 'B':
                return(3 + additonal);

            case 'C':
                return(2 + additonal);

            case 'D':
                return(1 + additonal);

            case 'F':
                return(0 + additonal);
            }
            return(0 + additonal);
        }
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            int gpa = 0;

            if (IsWeighted && (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled)))
            {
                gpa++;
            }
            switch (letterGrade)
            {
            case 'A':
                return(gpa + 4);

            case 'B':
                return(gpa + 3);

            case 'C':
                return(gpa + 2);

            case 'D':
                return(gpa + 1);

            case 'F':
                return(gpa);
            }
            return(0);
        }
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            int numericalGrade = 0;

            switch (letterGrade)
            {
            case 'A':
                numericalGrade = 4;
                break;

            case 'B':
                numericalGrade = 3;
                break;

            case 'C':
                numericalGrade = 2;
                break;

            case 'D':
                numericalGrade = 1;
                break;

            case 'F':
                numericalGrade = 0;
                break;
            }

            if ((studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled)) && IsWeighted)
            {
                numericalGrade++;
            }

            return(numericalGrade);
        }
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            int offset = 0;

            if (IsWeighted == true)
            {
                if (studentType.Equals("Honors") | studentType.Equals("DualEnrolled"))
                {
                    offset = 1;
                }
            }
            switch (letterGrade)
            {
            case 'A':
                return(4 + offset);

            case 'B':
                return(3 + offset);

            case 'C':
                return(2 + offset);

            case 'D':
                return(1 + offset);

            case 'F':
                return(0 + offset);
            }
            return(0);
        }
 private int AccountForWeighting(StudentType studentType, int gradePoints)
 {
     if (IsWeighted)
     {
         if (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled))
         {
             return(gradePoints + 1);
         }
     }
     return(gradePoints);
 }
Exemple #11
0
 private bool isAddExtraPoint(StudentType studentType)
 {
     if (IsWeighted &&
         (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled)))
     {
         return(true);
     }
     else
     {
         return(false);
     }
 }
Exemple #12
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            int IsWeightedAndHonorsOrDualEnrolled = 0;

            if (IsWeighted == true && (studentType.Equals(Enums.StudentType.Honors) || studentType.Equals(Enums.StudentType.DualEnrolled)))
            {
                IsWeightedAndHonorsOrDualEnrolled++;
            }
            switch (letterGrade)
            {
            case 'A':
                return(4 + IsWeightedAndHonorsOrDualEnrolled);

            case 'B':
                return(3 + IsWeightedAndHonorsOrDualEnrolled);

            case 'C':
                return(2 + IsWeightedAndHonorsOrDualEnrolled);

            case 'D':
                return(1 + IsWeightedAndHonorsOrDualEnrolled);

            case 'F':
                return(0 + IsWeightedAndHonorsOrDualEnrolled);
            }
            return(0);
        }
Exemple #13
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            var extraPoint = !studentType.Equals(StudentType.Standard) && IsWeighted ? true : false;

            switch (letterGrade)
            {
            case 'A':
                if (extraPoint)
                {
                    return(5);
                }
                else
                {
                    return(4);
                }

            case 'B':
                if (extraPoint)
                {
                    return(4);
                }
                else
                {
                    return(3);
                }

            case 'C':
                if (extraPoint)
                {
                    return(3);
                }
                else
                {
                    return(2);
                }

            case 'D':
                if (extraPoint)
                {
                    return(2);
                }
                else
                {
                    return(1);
                }

            case 'F':
                if (extraPoint)
                {
                    return(1);
                }
                else
                {
                    return(0);
                }
            }
            return(0);
        }
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            if (IsWeighted && (studentType.Equals("Honors") || studentType.Equals("DualEnrolled")))
            {
                switch (letterGrade)
                {
                case 'A':
                    return(5);

                case 'B':
                    return(4);

                case 'C':
                    return(3);

                case 'D':
                    return(2);

                case 'F':
                    return(1);
                }
            }
            else
            {
                switch (letterGrade)
                {
                case 'A':
                    return(4);

                case 'B':
                    return(3);

                case 'C':
                    return(2);

                case 'D':
                    return(1);

                case 'F':
                    return(0);
                }
            }
            return(0);
        }
Exemple #15
0
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            bool gpaFlag = IsWeighted && (studentType.Equals(StudentType.Honors) || studentType.Equals(StudentType.DualEnrolled));

            switch (letterGrade)
            {
            case 'A':
                return(gpaFlag ? 5 : 4);

            case 'B':
                return(gpaFlag ? 4 : 3);

            case 'C':
                return(gpaFlag ? 3 : 2);

            case 'D':
                return(gpaFlag ? 2 : 1);
            }
            return(0);
        }
        public virtual double GetGPA(char letterGrade, StudentType studentType)
        {
            if (studentType.Equals(GradeBook.Enums.StudentType.Honors) || studentType.Equals(GradeBook.Enums.StudentType.DualEnrolled))
            {
                if (IsWeighted == true)
                {
                    switch (letterGrade)
                    {
                    case 'A':
                        return(5);

                    case 'B':
                        return(4);

                    case 'C':
                        return(3);

                    case 'D':
                        return(2);

                    case 'F':
                        return(1);
                    }
                }
                else
                {
                    switch (letterGrade)
                    {
                    case 'A':
                        return(4);

                    case 'B':
                        return(3);

                    case 'C':
                        return(2);

                    case 'D':
                        return(1);

                    case 'F':
                        return(0);
                    }
                }
            }
            else
            {
                switch (letterGrade)
                {
                case 'A':
                    return(4);

                case 'B':
                    return(3);

                case 'C':
                    return(2);

                case 'D':
                    return(1);

                case 'F':
                    return(0);
                }
            }
            return(0);
        }