Examlex

Solved

Programming
Write a Static Method Named Graduation That Takes a Student's

question 2

Essay

Programming
Write a static method named graduation that takes a student's GPA, total credit count, and honors credit count as parameters, and returns a String representing that student's graduation status. The total credit count already includes the honors credits. The graduation status to return is determined by the following rules:
-Students must have completed at least 180 credits with a GPA of at least 2.0 to graduate. A student who does not meet both of these constraints should receive a return value of "not graduating".
-Students who do have enough credits to graduate and sufficiently high GPAs will receive one of four return values depending on the GPA and number of honors credits:
-All students with GPAs between 2.0 and 3.6 receive a return value of "graduating".
-Students with fewer than 15 honors credits receive a return of "cum laude" if their GPA is at least 3.6 but less than 3.8, and a return of "magna cum laude" if their GPA is at least 3.8.
-Students with 15 or more honors credits receive a return of "magna cum laude" if their GPA is at least 3.6 but less than 3.8, and a return of "summa cum laude" if their GPA is at least 3.8.
Here are some example calls to the method and their resulting return values:
 Call  Value Returned  graduation (3.87,178,16) "not graduating"  graduation (1.5,199,30) "not graduating"  graduation (2.7,380,50) "graduating"  graduation (3.6,180,14) "cum laude"  graduation (3.62,200,20) "magna cum laude"  graduation (3.93,185,0) "magna cum laude"  graduation (3.85,190,15) "surma cum laude" \begin{array}{l|l}\text { Call } & \text { Value Returned } \\\hline \text { graduation }(3.87,178,16) & \text { "not graduating" } \\\text { graduation }(1.5,199,30) & \text { "not graduating" } \\\text { graduation }(2.7,380,50) & \text { "graduating" } \\\text { graduation }(3.6,180,14) & \text { "cum laude" } \\\text { graduation }(3.62,200,20) & \text { "magna cum laude" } \\\text { graduation }(3.93,185,0) & \text { "magna cum laude" } \\\text { graduation }(3.85,190,15) & \text { "surma cum laude" }\end{array} You may assume that the GPA will be between 0.0 and 4.0 and that both credit counts will be non-negative integers.

Identify strategies for managing stress and the role of positive events (uplifts).
Understand the definition and examples of social categories and social groups, including primary groups.
Comprehend the criticisms against bureaucracies, along with notions of bureaucratic dehumanization and ritualism.
Differentiate between in-groups and out-groups, referencing their characteristics and examples.

Definitions:

Written Medium

A means of communication that involves the representation of language in a textual form, such as books, articles, or online content.

Confidential

Information or documents that are private or secret and not to be shared with unauthorized individuals.

Immediate Feedback

Instantaneous response or assessment given to a statement, performance, or action, facilitating rapid improvement.

Written Channels

Means of communication that involve writing, such as letters, emails, reports, or social media posts.

Related Questions